-/* $OpenBSD: cmd-new-session.c,v 1.71 2015/09/10 08:58:14 nicm Exp $ */
+/* $OpenBSD: cmd-new-session.c,v 1.72 2015/10/23 16:30:15 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
strerror(errno));
return (CMD_RETURN_ERROR);
}
- } else if (cp != NULL)
+ } else
free(cp);
cwd = fd;
} else if (c != NULL && c->session == NULL)
-/* $OpenBSD: cmd-new-window.c,v 1.46 2015/06/17 16:50:28 nicm Exp $ */
+/* $OpenBSD: cmd-new-window.c,v 1.47 2015/10/23 16:30:15 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
strerror(errno));
return (CMD_RETURN_ERROR);
}
- } else if (cp != NULL)
+ } else
free(cp);
cwd = fd;
} else if (cmdq->client != NULL && cmdq->client->session == NULL)
-/* $OpenBSD: cmd-split-window.c,v 1.57 2015/04/26 20:25:20 nicm Exp $ */
+/* $OpenBSD: cmd-split-window.c,v 1.58 2015/10/23 16:30:15 nicm Exp $ */
/*
* Copyright (c) 2009 Nicholas Marriott <nicm@users.sourceforge.net>
strerror(errno));
return (CMD_RETURN_ERROR);
}
- } else if (cp != NULL)
+ } else
free(cp);
cwd = fd;
} else if (cmdq->client != NULL && cmdq->client->session == NULL)
-/* $OpenBSD: tty.c,v 1.189 2015/10/23 15:52:54 nicm Exp $ */
+/* $OpenBSD: tty.c,v 1.190 2015/10/23 16:30:15 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
tty_close(tty);
free(tty->ccolour);
- if (tty->path != NULL)
- free(tty->path);
- if (tty->termname != NULL)
- free(tty->termname);
+ free(tty->path);
+ free(tty->termname);
}
void