diff options
author | Nicholas Marriott <nicm@openbsd.org> | 2010-08-22 16:09:49 +0000 |
---|---|---|
committer | Nicholas Marriott <nicm@openbsd.org> | 2010-08-22 16:09:49 +0000 |
commit | 5f5104e782782a26e436d5cfd59e3d38ad9063fa (patch) | |
tree | 5737172895994b0dd17364c9ef1b3588dbe940d2 /client.c | |
parent | e3be9b1951856f84d30c2903eccdf792618f71ba (diff) |
MSG_EXIT can now have a return code in the message, so check for that
size as well. Stops the client fatal()ing on exit.
Diffstat (limited to 'client.c')
-rw-r--r-- | client.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -297,7 +297,8 @@ client_dispatch(void) client_exitmsg = "detached"; break; case MSG_EXIT: - if (datalen != 0) + if (datalen != 0 && + datalen != sizeof (struct msg_exit_data)) fatalx("bad MSG_EXIT size"); client_write_server(MSG_EXITING, NULL, 0); |