diff options
author | 2015-08-30 15:43:40 +0000 | |
---|---|---|
committer | 2015-08-30 15:43:40 +0000 | |
commit | 82bdfec093f51523c8d7d41771438e101e5b491f (patch) | |
tree | c509f3eafd83f8aef013617162ffd36ba14ffc58 | |
parent | Eliminate a couple of extraneous DL_SECTOBLK() calls. (diff) | |
download | wireguard-openbsd-82bdfec093f51523c8d7d41771438e101e5b491f.tar.xz wireguard-openbsd-82bdfec093f51523c8d7d41771438e101e5b491f.zip |
Some style nits and dead assignments.
-rw-r--r-- | usr.bin/tmux/cmd-show-environment.c | 4 | ||||
-rw-r--r-- | usr.bin/tmux/cmd-swap-pane.c | 4 | ||||
-rw-r--r-- | usr.bin/tmux/server-client.c | 9 | ||||
-rw-r--r-- | usr.bin/tmux/tmux.c | 6 | ||||
-rw-r--r-- | usr.bin/tmux/xterm-keys.c | 4 |
5 files changed, 10 insertions, 17 deletions
diff --git a/usr.bin/tmux/cmd-show-environment.c b/usr.bin/tmux/cmd-show-environment.c index a32055bd5ec..6acc6af86f1 100644 --- a/usr.bin/tmux/cmd-show-environment.c +++ b/usr.bin/tmux/cmd-show-environment.c @@ -1,4 +1,4 @@ -/* $OpenBSD: cmd-show-environment.c,v 1.10 2015/07/13 13:36:29 nicm Exp $ */ +/* $OpenBSD: cmd-show-environment.c,v 1.11 2015/08/30 15:43:40 nicm Exp $ */ /* * Copyright (c) 2009 Nicholas Marriott <nicm@users.sourceforge.net> @@ -56,7 +56,7 @@ cmd_show_environment_escape(struct environ_entry *envent) } *out = '\0'; - return ret; + return (ret); } void diff --git a/usr.bin/tmux/cmd-swap-pane.c b/usr.bin/tmux/cmd-swap-pane.c index 100d18c7c17..d2feddb27cc 100644 --- a/usr.bin/tmux/cmd-swap-pane.c +++ b/usr.bin/tmux/cmd-swap-pane.c @@ -1,4 +1,4 @@ -/* $OpenBSD: cmd-swap-pane.c,v 1.20 2015/06/04 11:43:51 nicm Exp $ */ +/* $OpenBSD: cmd-swap-pane.c,v 1.21 2015/08/30 15:43:40 nicm Exp $ */ /* * Copyright (c) 2009 Nicholas Marriott <nicm@users.sourceforge.net> @@ -58,12 +58,10 @@ cmd_swap_pane_exec(struct cmd *self, struct cmd_q *cmdq) src_wp = TAILQ_NEXT(dst_wp, entry); if (src_wp == NULL) src_wp = TAILQ_FIRST(&dst_w->panes); - src_wl = dst_wl; } else if (args_has(self->args, 'U')) { src_wp = TAILQ_PREV(dst_wp, window_panes, entry); if (src_wp == NULL) src_wp = TAILQ_LAST(&dst_w->panes, window_panes); - src_wl = dst_wl; } else { src_wl = cmd_find_pane_marked(cmdq, NULL, NULL, &src_wp); diff --git a/usr.bin/tmux/server-client.c b/usr.bin/tmux/server-client.c index 9c72e0bb4ea..61bffec2382 100644 --- a/usr.bin/tmux/server-client.c +++ b/usr.bin/tmux/server-client.c @@ -1,4 +1,4 @@ -/* $OpenBSD: server-client.c,v 1.150 2015/08/29 08:54:41 nicm Exp $ */ +/* $OpenBSD: server-client.c,v 1.151 2015/08/30 15:43:40 nicm Exp $ */ /* * Copyright (c) 2009 Nicholas Marriott <nicm@users.sourceforge.net> @@ -551,13 +551,6 @@ server_client_handle_key(struct client *c, int key) w = s->curw->window; wp = w->active; - /* No session, do nothing. */ - if (c->session == NULL) - return; - s = c->session; - w = c->session->curw->window; - wp = w->active; - /* Update the activity timer. */ if (gettimeofday(&c->activity_time, NULL) != 0) fatal("gettimeofday failed"); diff --git a/usr.bin/tmux/tmux.c b/usr.bin/tmux/tmux.c index 320abcb10aa..cf3b7da6bd3 100644 --- a/usr.bin/tmux/tmux.c +++ b/usr.bin/tmux/tmux.c @@ -1,4 +1,4 @@ -/* $OpenBSD: tmux.c,v 1.137 2015/07/20 15:50:04 nicm Exp $ */ +/* $OpenBSD: tmux.c,v 1.138 2015/08/30 15:43:40 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net> @@ -198,7 +198,7 @@ shell_exec(const char *shell, const char *shellcmd) fatal("execl failed"); } -const char* +const char * find_home(void) { struct passwd *pw; @@ -213,7 +213,7 @@ find_home(void) home = NULL; } - return home; + return (home); } int diff --git a/usr.bin/tmux/xterm-keys.c b/usr.bin/tmux/xterm-keys.c index 3a2a697354b..92a0a5dc0ce 100644 --- a/usr.bin/tmux/xterm-keys.c +++ b/usr.bin/tmux/xterm-keys.c @@ -1,4 +1,4 @@ -/* $OpenBSD: xterm-keys.c,v 1.15 2014/07/21 10:25:48 nicm Exp $ */ +/* $OpenBSD: xterm-keys.c,v 1.16 2015/08/30 15:43:40 nicm Exp $ */ /* * Copyright (c) 2009 Nicholas Marriott <nicm@users.sourceforge.net> @@ -120,6 +120,8 @@ xterm_keys_match(const char *template, const char *buf, size_t len, size_t pos; int retval; + *modifiers = 0; + if (len == 0) return (0); |