diff options
author | drh <> | 2021-10-20 20:22:37 +0000 |
---|---|---|
committer | drh <> | 2021-10-20 20:22:37 +0000 |
commit | 8b554e2a1ea4de0cb30a49357684836710f44905 (patch) | |
tree | f72e01840592007819ecfcf520b0d7bfeaea22c6 /ext/misc/json1.c | |
parent | b18a11ed378d5255532ca01e900c67422164e552 (diff) | |
download | sqlite-8b554e2a1ea4de0cb30a49357684836710f44905.tar.gz sqlite-8b554e2a1ea4de0cb30a49357684836710f44905.zip |
Fix an incorrect JSON assert() that was added 5 days ago by check-in [7b8ea2298927fd34].
FossilOrigin-Name: e162da3ab4c183b67872be004035c48fc8f20084bc5757aec27410ce23a36631
Diffstat (limited to 'ext/misc/json1.c')
-rw-r--r-- | ext/misc/json1.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/ext/misc/json1.c b/ext/misc/json1.c index df6dcba76..70f344ea0 100644 --- a/ext/misc/json1.c +++ b/ext/misc/json1.c @@ -1680,7 +1680,8 @@ static JsonNode *jsonMergePatch( if( pParse->oom ) return 0; jsonRemoveAllNulls(pPatch); pTarget = &pParse->aNode[iTarget]; - assert( pParse->aNode[iRoot].eU==0 ); + assert( pParse->aNode[iRoot].eU==0 || pParse->aNode[iRoot].eU==2 ); + testcase( pParse->aNode[iRoot].eU==2 ); pParse->aNode[iRoot].jnFlags |= JNODE_APPEND; VVA( pParse->aNode[iRoot].eU = 2 ); pParse->aNode[iRoot].u.iAppend = iStart - iRoot; |