client/server echo program of UDP sockets
ive completed two of my tasks but im stuck in the third one..its a modified C program of UDP client/server echo.
briefly describing my program, the server has to accept two operands and the basic mathematical operator, process them and send the result back to the client.
the program should have the following features:
-the client should first ask the status of server that whether its running or dead.
-then the server should ask for the left operand. it sholud be sent by client and it shud be acknowledged by the server through some message.
-after that the server should ask for the operator (+,-,*,/) and acknowledge it.n repeat the same process for the right operand.
-after having all the data the server should process that mathematical expression and send back the result to the client n the client should display it.
ive tried various things, like multiple recvfrom() commands but its not working..im running it on fedora core7 environment. anybody who could help me n send me the code on my id firstname.lastname@example.org
i require it urgently by tonight.
i'l be obliged. thanku!
waiting for help!
1. This looks like homework which is against the forum rules. Asking for specific help is not a problem but do not ask us to do it for you.
2. Urgency on your part it not important for people who volunteer their free time to help others.
The best way to do this is to get the IPC working with a fork and either pipe or socketpair. Once that's working, figure out how to make the connections and separate the program into 2.
|All times are GMT -5. The time now is 08:53 AM.|