aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarc André Tanner <mat@brain-dump.org>2016-05-13 23:51:50 +0200
committerMarc André Tanner <mat@brain-dump.org>2016-05-14 00:06:46 +0200
commit66d7f9efac75a1920cdf152b9fcacc18adb059f9 (patch)
treed5ec5997968324a51728a0958d5d5e631724f9f9
parented0bbf0dc29e0107da604c83eebde4e17521c588 (diff)
downloadvis-66d7f9efac75a1920cdf152b9fcacc18adb059f9.tar.gz
vis-66d7f9efac75a1920cdf152b9fcacc18adb059f9.tar.xz
vis: allow :commands with a hyphen in the name
This fixes the argument parsing for the :{un,}map-window commands.
-rw-r--r--sam.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sam.c b/sam.c
index 3db08fd..1f5e816 100644
--- a/sam.c
+++ b/sam.c
@@ -328,7 +328,7 @@ static char *parse_cmdname(const char **s) {
Buffer buf;
buffer_init(&buf);
- while (isalpha((unsigned char)**s))
+ while (isalpha((unsigned char)**s) || **s == '-')
buffer_append(&buf, (*s)++, 1);
if (buffer_length(&buf))