diff options
author | Jean Boussier <[email protected]> | 2025-01-16 15:22:49 +0100 |
---|---|---|
committer | Hiroshi SHIBATA <[email protected]> | 2025-01-20 16:09:00 +0900 |
commit | f664e863d852bc331c33eb96fb03ac85cbb8171d (patch) | |
tree | 8f036ba6f11ec9ae9e447c5393ce32c6d3aae3ec /ext/json | |
parent | e4b54b0a3638ed89c6c0a9ca3f10b990b2bb008d (diff) |
[ruby/json] Use RSTRING_END
https://github.com/ruby/json/commit/dd9c46c805
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/12598
Diffstat (limited to 'ext/json')
-rw-r--r-- | ext/json/parser/parser.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/json/parser/parser.c b/ext/json/parser/parser.c index f777d7630b..f9ab9abfa0 100644 --- a/ext/json/parser/parser.c +++ b/ext/json/parser/parser.c @@ -1344,7 +1344,7 @@ static VALUE cParser_parse(JSON_ParserConfig *config, VALUE Vsource) JSON_ParserState _state = { .config = config, .cursor = RSTRING_PTR(Vsource), - .end = RSTRING_PTR(Vsource) + RSTRING_LEN(Vsource), + .end = RSTRING_END(Vsource), .stack = &stack, }; JSON_ParserState *state = &_state; |