From 3c742bfdc8f63e1cfed63a93571bb4e72e5f49c4 Mon Sep 17 00:00:00 2001 From: Paul Yang Date: Fri, 5 Oct 2018 11:12:23 -0700 Subject: Fix json ignore unknown (#128) * Fix json ignore unknown Previously, there were several problems with ignoring unknown in json. 1) After finding a field is unknown, the parser's state is not changed. Thus, there is no way to distinguish whether the parser is dealing with an unknown field or it's just a top level message. 2) Several method didn't respect unknown field, e.g., start_object, end_bool, start_array. * Update json parser size * Update json parser size --- upb/json/parser.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'upb/json/parser.h') diff --git a/upb/json/parser.h b/upb/json/parser.h index 316df08..15beaeb 100644 --- a/upb/json/parser.h +++ b/upb/json/parser.h @@ -29,7 +29,7 @@ UPB_DECLARE_DERIVED_TYPE(upb::json::ParserMethod, upb::RefCounted, * constructed. This hint may be an overestimate for some build configurations. * But if the parser library is upgraded without recompiling the application, * it may be an underestimate. */ -#define UPB_JSON_PARSER_SIZE 4160 +#define UPB_JSON_PARSER_SIZE 4672 #ifdef __cplusplus -- cgit v1.2.3