From: Bastien Dejean Date: Sun, 26 Jul 2020 17:28:43 +0000 (+0200) Subject: Reset some of the reference fields in query -{M,D} X-Git-Url: https://git.lizzy.rs/?a=commitdiff_plain;h=feeafe8ccb2b249ab73014674cb08b667d0bc845;p=bspwm.git Reset some of the reference fields in query -{M,D} Fixes #1111. --- diff --git a/src/messages.c b/src/messages.c index 7c34c0f..0d3978c 100644 --- a/src/messages.c +++ b/src/messages.c @@ -965,6 +965,8 @@ void cmd_query(char **args, int num, FILE *rsp) num--, args++; int ret; coordinates_t tmp = ref; + ref.desktop = NULL; + ref.node = NULL; if ((ret = monitor_from_desc(*args, &tmp, &ref)) != SELECTOR_OK) { handle_failure(ret, "query -M", *args, rsp); goto end; @@ -976,6 +978,7 @@ void cmd_query(char **args, int num, FILE *rsp) num--, args++; int ret; coordinates_t tmp = ref; + ref.node = NULL; if ((ret = desktop_from_desc(*args, &tmp, &ref)) != SELECTOR_OK) { handle_failure(ret, "query -D", *args, rsp); goto end;