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

Enable incorrect JSONB to be rendered into text without hitting an

assertion for a bad whitespace escape in a string.

FossilOrigin-Name: 4d6a9a217df6792b41766b774fb0c0553b45f9104c26a0955bf4a30862d7d7bf
This commit is contained in:
drh
2023-12-03 19:59:45 +00:00
parent 78fa0186b8
commit 0a18a5807a
3 changed files with 11 additions and 10 deletions

View File

@@ -2545,9 +2545,10 @@ static void jsonReturnFromBlob(
}else if( c=='\r' && z[i+1]=='\n' ){
iIn++;
continue;
}else if( 0xe2==(u8)c ){
assert( 0x80==(u8)z[i+1] );
assert( 0xa8==(u8)z[i+2] || 0xa9==(u8)z[i+2] );
}else if( 0xe2==(u8)c
&& 0x80==(u8)z[i+1]
&& (0xa8==(u8)z[i+2] || 0xa9==(u8)z[i+2])
){
iIn += 2;
continue;
}else{