diff options
author | Nicholas Marriott <nicholas.marriott@gmail.com> | 2015-07-14 08:15:05 +0100 |
---|---|---|
committer | Nicholas Marriott <nicholas.marriott@gmail.com> | 2015-07-14 08:15:05 +0100 |
commit | 5ffb869e1a543b264b9d94a19077d16f9832aff5 (patch) | |
tree | 59392329b2b678d46667e0960efa9e2c7dfb202a /server-client.c | |
parent | bed3069fd746741286e624126774f98ed51fbbdf (diff) | |
parent | dcc28434f460f637976ca313e062c0728d438e97 (diff) | |
download | rtmux-5ffb869e1a543b264b9d94a19077d16f9832aff5.tar.gz rtmux-5ffb869e1a543b264b9d94a19077d16f9832aff5.tar.bz2 rtmux-5ffb869e1a543b264b9d94a19077d16f9832aff5.zip |
Merge branch 'master' of github.com:tmux/tmux
Diffstat (limited to 'server-client.c')
-rw-r--r-- | server-client.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/server-client.c b/server-client.c index c9c0c3ef..59969618 100644 --- a/server-client.c +++ b/server-client.c @@ -95,6 +95,8 @@ server_client_create(int fd) environ_init(&c->environ); + c->cwd = -1; + c->cmdq = cmdq_new(c); c->cmdq->client_exit = 1; @@ -1267,12 +1269,11 @@ server_client_msg_identify(struct client *c, struct imsg *imsg) if (c->fd == -1) return; - if (!isatty(c->fd)) { + if (tty_init(&c->tty, c, c->fd, c->term) != 0) { close(c->fd); c->fd = -1; return; } - tty_init(&c->tty, c, c->fd, c->term); if (c->flags & CLIENT_UTF8) c->tty.flags |= TTY_UTF8; if (c->flags & CLIENT_256COLOURS) |