summaryrefslogtreecommitdiff
path: root/ext/json/parser
diff options
context:
space:
mode:
authortompng <[email protected]>2025-01-20 20:42:20 +0900
committerJean Boussier <[email protected]>2025-01-20 14:20:55 +0100
commitc026e44bb557dc42516785beba00452fa462738e ()
tree2842d554976bc9c7489c6f7083c3d17a277498cf /ext/json/parser
parent2b4b7bdb10dc8671bbc9e757f05bb74355891062 (diff)
[ruby/json] Fix parsing incomplete unicode escape "\uaaa"
https://.com/ruby/json/commit/86c0d4eb7e
Notes: Merged: https://.com/ruby/ruby/pull/12602
-rw-r--r--ext/json/parser/parser.c2
1 files changed, 1 insertions, 1 deletions
@@ -630,7 +630,7 @@ static VALUE json_string_unescape(JSON_ParserState *state, const char *string, c
unescape = (char *) "\f";
break;
case 'u':
- if (pe > stringEnd - 4) {
raise_parse_error("incomplete unicode character escape sequence at '%s'", p);
} else {
uint32_t ch = unescape_unicode((unsigned char *) ++pe);