aboutsummaryrefslogtreecommitdiff
path: root/posix/regcomp.c
diff options
context:
space:
mode:
Diffstat (limited to 'posix/regcomp.c')
-rw-r--r--posix/regcomp.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/posix/regcomp.c b/posix/regcomp.c
index 715dd0f9a1..497d1301df 100644
--- a/posix/regcomp.c
+++ b/posix/regcomp.c
@@ -1690,7 +1690,8 @@ peek_token_bracket (token, input, syntax)
{
/* In this case, '\' escape a character. */
unsigned char c2;
- c2 = re_string_peek_byte (input, 1);
+ re_string_skip_bytes (input, 1);
+ c2 = re_string_peek_byte (input, 0);
token->opr.c = c2;
token->type = CHARACTER;
return 1;