aboutsummaryrefslogtreecommitdiff
path: root/server.c
diff options
context:
space:
mode:
authorsotech117 <michael_foiani@brown.edu>2023-09-14 19:16:23 -0400
committersotech117 <michael_foiani@brown.edu>2023-09-14 19:16:23 -0400
commit663580b36a1b2590b7e706baa798e130297e88ee (patch)
tree3202db0b4e4b50c1d19390ae570ad0ef668cf077 /server.c
parentbbfbcc6c936b16568d96619f02f8bb081c190b2a (diff)
pass all tests on warmup
Diffstat (limited to 'server.c')
-rw-r--r--server.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/server.c b/server.c
index c17e039..5bfae9c 100644
--- a/server.c
+++ b/server.c
@@ -135,10 +135,10 @@ int main(int argc, char *argv[])
close(sockfd); // child doesn't need the listener
- // make a struct for the message, number is thennubmer of stations
+ // make a struct for the message, number is the number of stations
struct Welcome welcome;
welcome.replyType = 2;
- welcome.numStations = argc - 2;
+ welcome.numStations = htons(argc - 2);
if ((b = send(new_fd, &welcome, sizeof(struct Welcome), 0)) == -1)
perror("send");
close(new_fd);