diff options
Diffstat (limited to 'snowcast_server.c')
-rw-r--r-- | snowcast_server.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/snowcast_server.c b/snowcast_server.c index f09bfcc..e8f9525 100644 --- a/snowcast_server.c +++ b/snowcast_server.c @@ -138,6 +138,7 @@ int main(int argc, char *argv[]) get_in_addr((struct sockaddr*)&remoteaddr), remoteIP, INET6_ADDRSTRLEN), newfd); + // send the welcome message to client struct Welcome welcome; welcome.replyType = 2; @@ -160,8 +161,12 @@ int main(int argc, char *argv[]) FD_CLR(i, &master); // remove from master set } else { // we got some data from a client + if (command.commandType == 0) { + // hello message with udpPort + printf("udpPort (from Hello) for new connection is %d.\n", ntohs(command.number)); + } if (command.commandType == 1) { - // update the station for the user + // setStation command for the user printf("TODO: set station to %d\n", ntohs(command.number)); } else { |