ext/json/ext/parser/parser.rl in json_pure-1.0.3 vs ext/json/ext/parser/parser.rl in json_pure-1.0.4
- old
+ new
@@ -410,11 +410,11 @@
{
char *ptr;
long len;
GET_STRUCT;
source = StringValue(source);
- ptr = RSTRING(source)->ptr;
- len = RSTRING(source)->len;
+ ptr = RSTRING_PTR(source);
+ len = RSTRING_LEN(source);
if (len < 2) {
rb_raise(eParserError, "A JSON text must at least contain two octets!");
}
/*
Convert these?