aboutsummaryrefslogtreecommitdiff
path: root/cmd-find.c
diff options
context:
space:
mode:
authorThomas Adam <thomas@xteddy.org>2017-06-14 10:01:10 +0100
committerThomas Adam <thomas@xteddy.org>2017-06-14 10:01:10 +0100
commit91dec25fc96d17f99ba63115acf1cbbfb058d781 (patch)
treebef53ef0c8b685c0c8fc5658c3c4ef7b3015655d /cmd-find.c
parent6e57401610c98232ec5cfc791107c40a0dcc5720 (diff)
parentaf93453190c2fbb207c8541df33314160816985f (diff)
downloadrtmux-91dec25fc96d17f99ba63115acf1cbbfb058d781.tar.gz
rtmux-91dec25fc96d17f99ba63115acf1cbbfb058d781.tar.bz2
rtmux-91dec25fc96d17f99ba63115acf1cbbfb058d781.zip
Merge branch 'obsd-master'
Diffstat (limited to 'cmd-find.c')
-rw-r--r--cmd-find.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/cmd-find.c b/cmd-find.c
index e3b4a91f..ef1ce4aa 100644
--- a/cmd-find.c
+++ b/cmd-find.c
@@ -976,8 +976,11 @@ cmd_find_target(struct cmd_find_state *fs, struct cmdq_item *item,
} else if (cmd_find_from_client(&current, item->client) == 0) {
fs->current = &current;
log_debug("%s: current is from client", __func__);
- } else
+ } else {
+ if (~flags & CMD_FIND_QUIET)
+ cmdq_error(item, "no current target");
goto error;
+ }
if (!cmd_find_valid_state(fs->current))
fatalx("invalid current find state");