summaryrefslogtreecommitdiff
path: root/src/regexp_nfa.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2013-06-05 21:30:37 +0200
committerBram Moolenaar <Bram@vim.org>2013-06-05 21:30:37 +0200
commit2976c028ca65631825581dcd4e36b56ddc1ae82d (patch)
tree8fafacebdba6c8d43dd2552c14da819b8d5ea591 /src/regexp_nfa.c
parentc19b4b50a800c9866df4de0d30a25dc9d9af4939 (diff)
downloadvim-git-2976c028ca65631825581dcd4e36b56ddc1ae82d.tar.gz
updated for version 7.3.1127v7.3.1127
Problem: No error for using empty \%[]. Solution: Give error message.
Diffstat (limited to 'src/regexp_nfa.c')
-rw-r--r--src/regexp_nfa.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/regexp_nfa.c b/src/regexp_nfa.c
index 189e413ff..ec5543c46 100644
--- a/src/regexp_nfa.c
+++ b/src/regexp_nfa.c
@@ -977,6 +977,9 @@ nfa_regatom()
reg_magic == MAGIC_ALL);
EMIT(c);
}
+ if (n == 0)
+ EMSG2_RET_FAIL(_(e_empty_sb),
+ reg_magic == MAGIC_ALL);
EMIT(NFA_OPT_CHARS);
EMIT(n);
break;