aboutsummaryrefslogtreecommitdiffstats
path: root/string.c
diff options
context:
space:
mode:
Diffstat (limited to 'string.c')
-rw-r--r--string.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/string.c b/string.c
index 374dc86867..5bdc6d9fdd 100644
--- a/string.c
+++ b/string.c
@@ -1801,7 +1801,10 @@ trnext(t)
if (!t->gen) {
if (t->p == t->pend) return -1;
t->now = *(USTR)t->p++;
- if (t->p < t->pend - 1 && *t->p == '-') {
+ if (t->p < t->pend - 1 && *t->p == '\\') {
+ t->p++;
+ }
+ else if (t->p < t->pend - 1 && *t->p == '-') {
t->p++;
if (t->p < t->pend) {
if (t->now > *(USTR)t->p) {