summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsabetts <sabetts>2001-09-09 18:53:22 +0000
committersabetts <sabetts>2001-09-09 18:53:22 +0000
commit52331f356b10796b8c8a3748f1bccd16d692571d (patch)
tree4c9e4f479cb637e1dc27a9c1c8554734e94db724
parent22a8a1ba510dab1dfa3a3639825463d2678a3d34 (diff)
downloadratpoison-52331f356b10796b8c8a3748f1bccd16d692571d.zip
(cmd_windows): if data is NULL use the default format string.
-rw-r--r--ChangeLog1
-rw-r--r--src/actions.c5
2 files changed, 5 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index b355a4f..96f0139 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -7,6 +7,7 @@
arguments, not numbers.
(cmd_windows): Use the argument as a window format string in
non-interactive mode.
+ (cmd_windows): if data is NULL use the default format string.
2001-09-08 shawn <sabetts@diggin.lamenet.tmp>
diff --git a/src/actions.c b/src/actions.c
index 857bc9e..2f748aa 100644
--- a/src/actions.c
+++ b/src/actions.c
@@ -1006,7 +1006,10 @@ cmd_windows (int interactive, void *data)
else
{
window_list = sbuf_new (0);
- get_window_list ((char *)data, "\n", window_list, &dummy, &dummy);
+ if (data)
+ get_window_list ((char *)data, "\n", window_list, &dummy, &dummy);
+ else
+ get_window_list (defaults.window_fmt, "\n", window_list, &dummy, &dummy);
tmp = sbuf_get (window_list);
free (window_list);