mirror of
https://github.com/sqlite/sqlite.git
synced 2025-07-30 19:03:16 +03:00
Do not allow a comma at the end of a JSON array or object.
FossilOrigin-Name: 7c7a3f3e9bc2f7a7334d8d6eae183d83f22097be
This commit is contained in:
@ -606,7 +606,7 @@ static int jsonParseValue(JsonParse *pParse, u32 i){
|
||||
while( safe_isspace(pParse->zJson[j]) ){ j++; }
|
||||
x = jsonParseValue(pParse, j);
|
||||
if( x<0 ){
|
||||
if( x==(-2) ) return j+1;
|
||||
if( x==(-2) && pParse->nNode==(u32)iThis+1 ) return j+1;
|
||||
return -1;
|
||||
}
|
||||
if( pParse->oom ) return -1;
|
||||
@ -636,7 +636,7 @@ static int jsonParseValue(JsonParse *pParse, u32 i){
|
||||
while( safe_isspace(pParse->zJson[j]) ){ j++; }
|
||||
x = jsonParseValue(pParse, j);
|
||||
if( x<0 ){
|
||||
if( x==(-3) ) return j+1;
|
||||
if( x==(-3) && pParse->nNode==(u32)iThis+1 ) return j+1;
|
||||
return -1;
|
||||
}
|
||||
j = x;
|
||||
|
Reference in New Issue
Block a user