1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-09 14:21:03 +03:00

Minor changes to make coverage testing easier.

FossilOrigin-Name: ec8b43382e5402e15d9f2dda3cf21ac8be8c1589ddbe6c9433c33eef0036f764
This commit is contained in:
drh
2023-07-26 21:53:09 +00:00
parent 3f3dc2f5d8
commit f7a164f345
3 changed files with 13 additions and 10 deletions

View File

@@ -2828,14 +2828,17 @@ static void jsonReplaceNode(
break;
}
if( sqlite3_value_subtype(pValue)!=JSON_SUBTYPE ){
int k = jsonParseAddNode(p, JSON_STRING, n, z);
char *zCopy = sqlite3DbStrDup(0, z);
if( k>0 ) p->aNode[k].jnFlags |= JNODE_RAW;
int k;
if( zCopy ){
jsonParseAddCleanup(p, sqlite3_free, zCopy);
}else{
}else{
p->oom = 1;
sqlite3_result_error_nomem(pCtx);
}
k = jsonParseAddNode(p, JSON_STRING, n, zCopy);
assert( k>0 || p->oom );
if( p->oom==0 ) p->aNode[k].jnFlags |= JNODE_RAW;
}else{
JsonParse *pPatch = jsonParseCached(pCtx, pValue, pCtx, 1);
if( pPatch==0 ){