summaryrefslogtreecommitdiff
path: root/usr.bin/tmux/cmd-switch-client.c
diff options
context:
space:
mode:
authorNicholas Marriott <nicm@cvs.openbsd.org>2017-01-24 20:15:33 +0000
committerNicholas Marriott <nicm@cvs.openbsd.org>2017-01-24 20:15:33 +0000
commit6feccbfb8530026d713a2a90c60108635fb3abeb (patch)
treeadf1795876b23b248889e990c9c87675a464c0f7 /usr.bin/tmux/cmd-switch-client.c
parent5e3f53613e55106d6b61636be22cede72866d391 (diff)
Make update-environment an array as well.
Diffstat (limited to 'usr.bin/tmux/cmd-switch-client.c')
-rw-r--r--usr.bin/tmux/cmd-switch-client.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/usr.bin/tmux/cmd-switch-client.c b/usr.bin/tmux/cmd-switch-client.c
index b4680165bef..ffd45dc692f 100644
--- a/usr.bin/tmux/cmd-switch-client.c
+++ b/usr.bin/tmux/cmd-switch-client.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cmd-switch-client.c,v 1.45 2017/01/06 13:26:09 nicm Exp $ */
+/* $OpenBSD: cmd-switch-client.c,v 1.46 2017/01/24 20:15:32 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicholas.marriott@gmail.com>
@@ -53,7 +53,7 @@ cmd_switch_client_exec(struct cmd *self, struct cmdq_item *item)
struct client *c = state->c;
struct session *s = item->state.tflag.s;
struct window_pane *wp;
- const char *tablename, *update;
+ const char *tablename;
struct key_table *table;
if (args_has(args, 'r'))
@@ -102,10 +102,8 @@ cmd_switch_client_exec(struct cmd *self, struct cmdq_item *item)
}
}
- if (!args_has(args, 'E')) {
- update = options_get_string(s->options, "update-environment");
- environ_update(update, c->environ, s->environ);
- }
+ if (!args_has(args, 'E'))
+ environ_update(s->options, c->environ, s->environ);
if (c->session != NULL && c->session != s)
c->last_session = c->session;