summaryrefslogtreecommitdiff
path: root/usr.bin/tmux/cmd-split-window.c
diff options
context:
space:
mode:
authorNicholas Marriott <nicm@cvs.openbsd.org>2013-03-25 15:59:58 +0000
committerNicholas Marriott <nicm@cvs.openbsd.org>2013-03-25 15:59:58 +0000
commit8719864660c5c508599035e11298e4116b707f6d (patch)
tree87d8b6825fc964fe60d439b909ddc738202546a7 /usr.bin/tmux/cmd-split-window.c
parent9e5b1f06effb0aefc0381cf2da1fcb10faa96101 (diff)
Revert the command-prefix change which breaks sequences of commands.
Diffstat (limited to 'usr.bin/tmux/cmd-split-window.c')
-rw-r--r--usr.bin/tmux/cmd-split-window.c19
1 files changed, 5 insertions, 14 deletions
diff --git a/usr.bin/tmux/cmd-split-window.c b/usr.bin/tmux/cmd-split-window.c
index 14f911cbebe..8a072121dbb 100644
--- a/usr.bin/tmux/cmd-split-window.c
+++ b/usr.bin/tmux/cmd-split-window.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cmd-split-window.c,v 1.41 2013/03/24 09:57:59 nicm Exp $ */
+/* $OpenBSD: cmd-split-window.c,v 1.42 2013/03/25 15:59:57 nicm Exp $ */
/*
* Copyright (c) 2009 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -59,8 +59,8 @@ cmd_split_window_exec(struct cmd *self, struct cmd_q *cmdq)
struct window *w;
struct window_pane *wp, *new_wp = NULL;
struct environ env;
- const char *cmd, *cwd, *shell, *prefix;
- char *cause, *new_cause, *cmd1;
+ const char *cmd, *cwd, *shell;
+ char *cause, *new_cause;
u_int hlimit;
int size, percentage;
enum layout_type type;
@@ -123,18 +123,9 @@ cmd_split_window_exec(struct cmd *self, struct cmd_q *cmdq)
goto error;
}
new_wp = window_add_pane(w, hlimit);
-
- if (*cmd != '\0') {
- prefix = options_get_string(&w->options, "command-prefix");
- xasprintf(&cmd1, "%s%s", prefix, cmd);
- } else
- cmd1 = xstrdup("");
- if (window_pane_spawn(new_wp, cmd1, shell, cwd, &env, s->tio,
- &cause) != 0) {
- free(cmd1);
+ if (window_pane_spawn(
+ new_wp, cmd, shell, cwd, &env, s->tio, &cause) != 0)
goto error;
- }
- free(cmd1);
layout_assign_pane(lc, new_wp);
server_redraw_window(w);