File tree 2 files changed +6
-6
lines changed
src/main/java/com/fasterxml/jackson/databind 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -92,7 +92,7 @@ public void close() throws IOException
92
92
if (!_closed ) {
93
93
_closed = true ;
94
94
_nodeCursor = null ;
95
- _currToken = null ;
95
+ _updateTokenToNull () ;
96
96
}
97
97
}
98
98
@@ -105,7 +105,7 @@ public void close() throws IOException
105
105
@ Override
106
106
public JsonToken nextToken () throws IOException
107
107
{
108
- _currToken = _nodeCursor .nextToken ();
108
+ _updateToken ( _nodeCursor .nextToken () );
109
109
if (_currToken == null ) {
110
110
_closed = true ; // if not already set
111
111
return null ;
@@ -133,10 +133,10 @@ public JsonParser skipChildren() throws IOException
133
133
{
134
134
if (_currToken == JsonToken .START_OBJECT ) {
135
135
_nodeCursor = _nodeCursor .getParent ();
136
- _currToken = JsonToken .END_OBJECT ;
136
+ _updateToken ( JsonToken .END_OBJECT ) ;
137
137
} else if (_currToken == JsonToken .START_ARRAY ) {
138
138
_nodeCursor = _nodeCursor .getParent ();
139
- _currToken = JsonToken .END_ARRAY ;
139
+ _updateToken ( JsonToken .END_ARRAY ) ;
140
140
}
141
141
return this ;
142
142
}
Original file line number Diff line number Diff line change @@ -1641,7 +1641,7 @@ public JsonToken nextToken() throws IOException
1641
1641
return null ;
1642
1642
}
1643
1643
}
1644
- _currToken = _segment .type (_segmentPtr );
1644
+ _updateToken ( _segment .type (_segmentPtr ) );
1645
1645
// Field name? Need to update context
1646
1646
if (_currToken == JsonToken .FIELD_NAME ) {
1647
1647
Object ob = _currentObject ();
@@ -1672,7 +1672,7 @@ public String nextFieldName() throws IOException
1672
1672
int ptr = _segmentPtr +1 ;
1673
1673
if ((ptr < Segment .TOKENS_PER_SEGMENT ) && (_segment .type (ptr ) == JsonToken .FIELD_NAME )) {
1674
1674
_segmentPtr = ptr ;
1675
- _currToken = JsonToken .FIELD_NAME ;
1675
+ _updateToken ( JsonToken .FIELD_NAME ) ;
1676
1676
Object ob = _segment .get (ptr ); // inlined _currentObject();
1677
1677
String name = (ob instanceof String ) ? ((String ) ob ) : ob .toString ();
1678
1678
_parsingContext .setCurrentName (name );
You can’t perform that action at this time.
0 commit comments