mirror of
https://github.com/google/flatbuffers.git
synced 2026-06-02 12:05:50 +00:00
Fix #3775: Skip unknown field names if they're quoted
This commit is contained in:
@@ -1557,8 +1557,12 @@ CheckedError Parser::SkipJsonObject() {
|
||||
for (;;) {
|
||||
if ((!opts.strict_json || !fieldn) && Is('}')) break;
|
||||
|
||||
if (!Is(kTokenStringConstant))
|
||||
if (!Is(kTokenStringConstant)) {
|
||||
EXPECT(opts.strict_json ? kTokenStringConstant : kTokenIdentifier);
|
||||
}
|
||||
else {
|
||||
NEXT();
|
||||
}
|
||||
|
||||
EXPECT(':');
|
||||
ECHECK(SkipAnyJsonValue());
|
||||
|
||||
Reference in New Issue
Block a user