diff options
author | Nicholas Marriott <nicholas.marriott@gmail.com> | 2013-02-19 09:51:04 +0000 |
---|---|---|
committer | Nicholas Marriott <nicholas.marriott@gmail.com> | 2013-02-19 09:51:04 +0000 |
commit | a96dd1932ad43457e710d154edccbfb08c1c2520 (patch) | |
tree | 7387a58fed7bd3038b773aebe4ffd93b1d0f3a40 /cmd-capture-pane.c | |
parent | 693244795c36ef0d955aa7095ffd335a1846fe05 (diff) | |
download | rtmux-a96dd1932ad43457e710d154edccbfb08c1c2520.tar.gz rtmux-a96dd1932ad43457e710d154edccbfb08c1c2520.tar.bz2 rtmux-a96dd1932ad43457e710d154edccbfb08c1c2520.zip |
Don't use a target-client for stdout, just always cmdclient.
Diffstat (limited to 'cmd-capture-pane.c')
-rw-r--r-- | cmd-capture-pane.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/cmd-capture-pane.c b/cmd-capture-pane.c index 0fd05f9c..3c09d1c4 100644 --- a/cmd-capture-pane.c +++ b/cmd-capture-pane.c @@ -31,9 +31,8 @@ enum cmd_retval cmd_capture_pane_exec(struct cmd *, struct cmd_ctx *); const struct cmd_entry cmd_capture_pane_entry = { "capture-pane", "capturep", - "b:c:E:pS:t:", 0, 0, - "[-p] [-c target-client] [-b buffer-index] [-E end-line] " - "[-S start-line] " + "b:E:pS:t:", 0, 0, + "[-p] [-b buffer-index] [-E end-line] [-S start-line]" CMD_TARGET_PANE_USAGE, 0, NULL, @@ -45,7 +44,7 @@ enum cmd_retval cmd_capture_pane_exec(struct cmd *self, struct cmd_ctx *ctx) { struct args *args = self->args; - struct client *c; + struct client *c = ctx->cmdclient; struct window_pane *wp; char *buf, *line, *cause; struct screen *s; @@ -54,9 +53,6 @@ cmd_capture_pane_exec(struct cmd *self, struct cmd_ctx *ctx) u_int i, limit, top, bottom, tmp; size_t len, linelen; - if ((c = cmd_find_client(ctx, args_get(args, 'c'))) == NULL) - return (CMD_RETURN_ERROR); - if (cmd_find_pane(ctx, args_get(args, 't'), NULL, &wp) == NULL) return (CMD_RETURN_ERROR); s = &wp->base; |