diff options
author | Nicholas Marriott <nicholas.marriott@gmail.com> | 2013-03-04 09:02:32 +0000 |
---|---|---|
committer | Nicholas Marriott <nicholas.marriott@gmail.com> | 2013-03-04 09:02:32 +0000 |
commit | 43d904dbf396f5ce90e29915b416fd26e32c6c3e (patch) | |
tree | 192a95643e1327515e1dd8da568d2d3905b10cec /cmd-choose-client.c | |
parent | 1da64bf786d2f139b822bc80ef6043443c0ea720 (diff) | |
download | rtmux-43d904dbf396f5ce90e29915b416fd26e32c6c3e.tar.gz rtmux-43d904dbf396f5ce90e29915b416fd26e32c6c3e.tar.bz2 rtmux-43d904dbf396f5ce90e29915b416fd26e32c6c3e.zip |
tty.path can be NULL, don't dereference it. From George Nachman.
Diffstat (limited to 'cmd-choose-client.c')
-rw-r--r-- | cmd-choose-client.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cmd-choose-client.c b/cmd-choose-client.c index ce569ff4..40752a70 100644 --- a/cmd-choose-client.c +++ b/cmd-choose-client.c @@ -79,7 +79,7 @@ cmd_choose_client_exec(struct cmd *self, struct cmd_q *cmdq) cur = idx = 0; for (i = 0; i < ARRAY_LENGTH(&clients); i++) { c1 = ARRAY_ITEM(&clients, i); - if (c1 == NULL || c1->session == NULL) + if (c1 == NULL || c1->session == NULL || c1->tty.path == NULL) continue; if (c1 == cmdq->client) cur = idx; |