mirror of
https://github.com/tmux/tmux.git
synced 2024-12-13 01:48:47 +00:00
Print a better message than '(null)' if no command is specified ("tmux \;").
This commit is contained in:
parent
38b2c42f63
commit
85e0d8a221
4
cmd.c
4
cmd.c
@ -108,8 +108,10 @@ cmd_parse(int argc, char **argv, char **cause)
|
|||||||
int opt;
|
int opt;
|
||||||
|
|
||||||
*cause = NULL;
|
*cause = NULL;
|
||||||
if (argc == 0)
|
if (argc == 0) {
|
||||||
|
xasprintf(cause, "no command");
|
||||||
return (NULL);
|
return (NULL);
|
||||||
|
}
|
||||||
|
|
||||||
entry = NULL;
|
entry = NULL;
|
||||||
for (entryp = cmd_table; *entryp != NULL; entryp++) {
|
for (entryp = cmd_table; *entryp != NULL; entryp++) {
|
||||||
|
Loading…
Reference in New Issue
Block a user