From abd1399a7f28e03a1861aa077dca8d72420b5ee8 Mon Sep 17 00:00:00 2001 From: John Keiser Date: Fri, 7 Aug 2020 11:06:33 -0700 Subject: [PATCH] Don't check depth at the end (unnecessary check) --- src/generic/stage2/json_iterator.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/generic/stage2/json_iterator.h b/src/generic/stage2/json_iterator.h index 34754065..ebe9094d 100644 --- a/src/generic/stage2/json_iterator.h +++ b/src/generic/stage2/json_iterator.h @@ -188,8 +188,6 @@ document_end: dom_parser.next_structural_index = uint32_t(next_structural - &dom_parser.structural_indexes[0]); - if (depth != 0) { log_error("Unclosed objects or arrays!"); return TAPE_ERROR; } - // If we didn't make it to the end, it's an error if ( !STREAMING && dom_parser.next_structural_index != dom_parser.n_structural_indexes ) { log_error("More than one JSON value at the root of the document, or extra characters at the end of the JSON!");