Client/Server Programming: Default argument for unknown service name?
Posted on 2004-10-24
I am writing a client server program that doesn't have a specific service name...
I am really only familiar with the "echo" and "time" service. What should I have as
a default argument for the service if this is something I'm making myself?
void main(int argc, char *argv)
char *service = argv; //port number??????
char *host ="localhost"; //IP address
//arguments are entered in on the command line
WSADATA wsadata; //Creating a WSADATA object called wsadata
case 1: break;
case 2: service = argv;
case 3: service = argv;
host = argv;
default: errexit("usage: TCPmusic[port]\n");
AND SO ON....ETC...