Fix some warnings, GitHub issue 2382.

This commit is contained in:
nicm
2020-09-16 18:37:55 +00:00
parent 1fed7e84a3
commit 869c0e860f
5 changed files with 10 additions and 30 deletions

View File

@ -158,7 +158,7 @@ server_start(struct tmuxproc *client, int flags, struct event_base *base,
{
int pair[2];
sigset_t set, oldset;
struct client *c;
struct client *c = NULL;
char *cause = NULL;
sigfillset(&set);
@ -224,9 +224,11 @@ server_start(struct tmuxproc *client, int flags, struct event_base *base,
}
if (cause != NULL) {
cmdq_append(c, cmdq_get_error(cause));
if (c != NULL) {
cmdq_append(c, cmdq_get_error(cause));
c->flags |= CLIENT_EXIT;
}
free(cause);
c->flags |= CLIENT_EXIT;
}
server_add_accept(0);