-/* $OpenBSD: cmd-find.c,v 1.53 2017/06/14 07:37:17 nicm Exp $ */
+/* $OpenBSD: cmd-find.c,v 1.54 2017/06/16 15:12:38 nicm Exp $ */
/*
* Copyright (c) 2015 Nicholas Marriott <nicholas.marriott@gmail.com>
struct mouse_event *m;
struct cmd_find_state current;
char *colon, *period, *copy = NULL;
- const char *session, *window, *pane;
+ const char *session, *window, *pane, *s;
int window_only = 0, pane_only = 0;
/* Can fail flag implies quiet. */
flags |= CMD_FIND_QUIET;
/* Log the arguments. */
+ if (type == CMD_FIND_PANE)
+ s = "pane";
+ else if (type == CMD_FIND_WINDOW)
+ s = "window";
+ else if (type == CMD_FIND_SESSION)
+ s = "session";
+ else
+ s = "unknown";
if (target == NULL)
- log_debug("%s: target none, type %d", __func__, type);
+ log_debug("%s: target none, type %s", __func__, s);
else
- log_debug("%s: target %s, type %d", __func__, target, type);
+ log_debug("%s: target %s, type %s", __func__, target, s);
log_debug("%s: item %p, flags %#x", __func__, item, flags);
/* Clear new state. */
-/* $OpenBSD: cmd-queue.c,v 1.56 2017/05/30 21:44:59 nicm Exp $ */
+/* $OpenBSD: cmd-queue.c,v 1.57 2017/06/16 15:12:38 nicm Exp $ */
/*
* Copyright (c) 2013 Nicholas Marriott <nicholas.marriott@gmail.com>
msglen = xvasprintf(&msg, fmt, ap);
va_end(ap);
+ log_debug("%s: %s", __func__, msg);
+
if (c == NULL)
cfg_add_cause("%s:%u: %s", cmd->file, cmd->line, msg);
else if (c->session == NULL || (c->flags & CLIENT_CONTROL)) {