avro-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From th...@apache.org
Subject [1/2] avro git commit: AVRO-1995: JSON Parser does not properly check current state
Date Tue, 31 Jan 2017 05:24:48 GMT
Repository: avro
Updated Branches:
  refs/heads/master cc31afef4 -> 2ac78613d


AVRO-1995: JSON Parser does not properly check current state


Project: http://git-wip-us.apache.org/repos/asf/avro/repo
Commit: http://git-wip-us.apache.org/repos/asf/avro/commit/92b83f5a
Tree: http://git-wip-us.apache.org/repos/asf/avro/tree/92b83f5a
Diff: http://git-wip-us.apache.org/repos/asf/avro/diff/92b83f5a

Branch: refs/heads/master
Commit: 92b83f5a6ca234b2ac7e3323e3bd2e0b58c758f0
Parents: cc31afe
Author: Victor Mota <vimota@gmail.com>
Authored: Mon Jan 30 11:31:09 2017 -0800
Committer: Victor Mota <vimota@gmail.com>
Committed: Mon Jan 30 11:31:09 2017 -0800

----------------------------------------------------------------------
 lang/c++/impl/json/JsonIO.cc | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/avro/blob/92b83f5a/lang/c++/impl/json/JsonIO.cc
----------------------------------------------------------------------
diff --git a/lang/c++/impl/json/JsonIO.cc b/lang/c++/impl/json/JsonIO.cc
index eafd579..be5cc2f 100644
--- a/lang/c++/impl/json/JsonIO.cc
+++ b/lang/c++/impl/json/JsonIO.cc
@@ -76,7 +76,7 @@ JsonParser::Token JsonParser::doAdvance()
 {
     char ch = next();
     if (ch == ']') {
-        if (curState == stArray0 || stArrayN) {
+        if (curState == stArray0 || curState == stArrayN) {
             curState = stateStack.top();
             stateStack.pop();
             return tkArrayEnd;
@@ -84,7 +84,7 @@ JsonParser::Token JsonParser::doAdvance()
             throw unexpected(ch);
         }
     } else if (ch == '}') {
-        if (curState == stObject0 || stObjectN) {
+        if (curState == stObject0 || curState == stObjectN) {
             curState = stateStack.top();
             stateStack.pop();
             return tkObjectEnd;


Mime
View raw message