aboutsummaryrefslogtreecommitdiff
path: root/snowcast_server_concurrent.c
diff options
context:
space:
mode:
Diffstat (limited to 'snowcast_server_concurrent.c')
-rw-r--r--snowcast_server_concurrent.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/snowcast_server_concurrent.c b/snowcast_server_concurrent.c
index 4fa6d40..5a4ff9f 100644
--- a/snowcast_server_concurrent.c
+++ b/snowcast_server_concurrent.c
@@ -569,23 +569,26 @@ void *select_thread(void *arg) {
// check if user has a udpPort
if (user_data[sockfd_to_user[i]].udpPort == -1) {
// send back in invalid command
- char * message = "Must send Hello message first";
+ char * message = "Must send Hello message first.";
send_invalid_command_reply(i, strlen(message), message);
// drop connection upon invalid command
close(i);
FD_CLR(i, &master);
destroy_user(i);
+ continue;
}
int station_num = ntohs(command.number);
+ printf("station_num: %d\n", station_num);
if (station_num >= num_stations || station_num < 0) {
// send back in invalid command
- char * message = "Station number out of range";
+ char * message = "Station number out of range.";
send_invalid_command_reply(i, strlen(message), message);
// drop connection upon invalid command
close(i);
FD_CLR(i, &master);
destroy_user(i);
+ continue;
}
// printf("setting station to %d\n", ntohs(command.number));