diff options
author | Thomas Adam <thomas@xteddy.org> | 2022-07-06 12:01:09 +0100 |
---|---|---|
committer | Thomas Adam <thomas@xteddy.org> | 2022-07-06 12:01:09 +0100 |
commit | dc6bc0e95acc04cdf43e869294ecba897a11d850 (patch) | |
tree | 43f64841f177d2bce5e0b1020fb2ddba9b3aad9d | |
parent | b130e951cc3157ef4deeadc25cc668b8e355f234 (diff) | |
parent | 1afe22086fb85a596eb4a20f2e80cacfbbc2f1e5 (diff) | |
download | rtmux-dc6bc0e95acc04cdf43e869294ecba897a11d850.tar.gz rtmux-dc6bc0e95acc04cdf43e869294ecba897a11d850.tar.bz2 rtmux-dc6bc0e95acc04cdf43e869294ecba897a11d850.zip |
Merge branch 'obsd-master'
-rw-r--r-- | cmd-attach-session.c | 3 | ||||
-rw-r--r-- | cmd-new-session.c | 10 | ||||
-rw-r--r-- | control.c | 8 | ||||
-rw-r--r-- | server-client.c | 5 | ||||
-rw-r--r-- | tmux.1 | 12 | ||||
-rw-r--r-- | tmux.h | 1 |
6 files changed, 26 insertions, 13 deletions
diff --git a/cmd-attach-session.c b/cmd-attach-session.c index b92a7f2b..4e2d15da 100644 --- a/cmd-attach-session.c +++ b/cmd-attach-session.c @@ -158,6 +158,9 @@ cmd_attach_session(struct cmdq_item *item, const char *tflag, int dflag, c->flags |= CLIENT_ATTACHED; } + if (cfg_finished) + cfg_show_causes(s); + return (CMD_RETURN_NORMAL); } diff --git a/cmd-new-session.c b/cmd-new-session.c index b946f049..c90369bc 100644 --- a/cmd-new-session.c +++ b/cmd-new-session.c @@ -333,13 +333,6 @@ cmd_new_session_exec(struct cmd *self, struct cmdq_item *item) server_client_set_key_table(c, NULL); } - /* - * If there are still configuration file errors to display, put the new - * session's current window into view mode and display them now. - */ - if (cfg_finished) - cfg_show_causes(s); - /* Print if requested. */ if (args_has(args, 'P')) { if ((template = args_get(args, 'F')) == NULL) @@ -357,6 +350,9 @@ cmd_new_session_exec(struct cmd *self, struct cmdq_item *item) cmd_find_from_session(&fs, s, 0); cmdq_insert_hook(s, item, &fs, "after-new-session"); + if (cfg_finished) + cfg_show_causes(s); + if (sc.argv != NULL) cmd_free_argv(sc.argc, sc.argv); free(cwd); @@ -775,7 +775,6 @@ control_start(struct client *c) cs->read_event = bufferevent_new(c->fd, control_read_callback, control_write_callback, control_error_callback, c); - bufferevent_enable(cs->read_event, EV_READ); if (c->flags & CLIENT_CONTROLCONTROL) cs->write_event = cs->read_event; @@ -792,6 +791,13 @@ control_start(struct client *c) } } +/* Control client ready. */ +void +control_ready(struct client *c) +{ + bufferevent_enable(c->control_state->read_event, EV_READ); +} + /* Discard all output for a client. */ void control_discard(struct client *c) diff --git a/server-client.c b/server-client.c index 8144bcd5..f1b32158 100644 --- a/server-client.c +++ b/server-client.c @@ -2788,8 +2788,11 @@ server_client_command_done(struct cmdq_item *item, __unused void *data) if (~c->flags & CLIENT_ATTACHED) c->flags |= CLIENT_EXIT; - else if (~c->flags & CLIENT_EXIT) + else if (~c->flags & CLIENT_EXIT) { + if (c->flags & CLIENT_CONTROL) + control_ready(c); tty_send_requests(&c->tty); + } return (CMD_RETURN_NORMAL); } @@ -2115,9 +2115,11 @@ is not given, "detach-client -t '%%'" is used. specifies the initial sort field: one of .Ql name , .Ql size , -.Ql creation , +.Ql creation +(time), or -.Ql activity . +.Ql activity +(time). .Fl r reverses the sort order. .Fl f @@ -2199,7 +2201,8 @@ specifies the initial sort field: one of .Ql index , .Ql name , or -.Ql time . +.Ql time +(activity). .Fl r reverses the sort order. .Fl f @@ -6110,7 +6113,8 @@ is not given, "paste-buffer -b '%%'" is used. .Pp .Fl O specifies the initial sort field: one of -.Ql time , +.Ql time +(creation), .Ql name or .Ql size . @@ -3136,6 +3136,7 @@ char *parse_window_name(const char *); /* control.c */ void control_discard(struct client *); void control_start(struct client *); +void control_ready(struct client *); void control_stop(struct client *); void control_set_pane_on(struct client *, struct window_pane *); void control_set_pane_off(struct client *, struct window_pane *); |