1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-11 01:42:22 +03:00

Fix an issue that can arise when processing corrupt JSONB.

FossilOrigin-Name: e50045c22296be84c6bea82bb8b310f07bca820c84d4a7349b16da0cf5d2657c
This commit is contained in:
drh
2023-10-11 12:44:17 +00:00
parent 33b56217cb
commit 2b7a1f5926
3 changed files with 8 additions and 8 deletions

View File

@@ -2209,7 +2209,7 @@ static JsonParse *jsonParseCached(
** a match.
*/
static int jsonLabelCompare(const JsonNode *pNode, const char *zKey, u32 nKey){
assert( pNode->eU==1 );
if( pNode->eType!=JSON_STRING ) return 0;
if( pNode->n!=nKey ) return 0;
return strncmp(pNode->u.zJContent, zKey, nKey)==0;
}