diff options
author | Nicholas Marriott <nicm@openbsd.org> | 2009-06-04 23:34:32 +0000 |
---|---|---|
committer | Nicholas Marriott <nicm@openbsd.org> | 2009-06-04 23:34:32 +0000 |
commit | 85e0d8a221314869458169955f218c9971f5bcb6 (patch) | |
tree | 19b213fe3d57c97ca475ddba7bc3a92c934c9417 /cmd.c | |
parent | 38b2c42f63eaa5fcd6f750aafc756b2a5e5b4395 (diff) |
Print a better message than '(null)' if no command is specified ("tmux \;").
Diffstat (limited to 'cmd.c')
-rw-r--r-- | cmd.c | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -108,8 +108,10 @@ cmd_parse(int argc, char **argv, char **cause) int opt; *cause = NULL; - if (argc == 0) + if (argc == 0) { + xasprintf(cause, "no command"); return (NULL); + } entry = NULL; for (entryp = cmd_table; *entryp != NULL; entryp++) { |