1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-08-08 14:02:16 +03:00

Fix a bug in the NOT NULL/IS NULL optimization of check-in [cb94350185f555c3]

that can cause invalid data to be used for a column if that column has a
CHECK constraint that includes the NOT NULL or IS NULL operator.
Problem discovered by the 
[https://issues.chromium.org/issues/415397143|Chromium fuzzer].  Never
seen in the wild, as far as anybody knows.

FossilOrigin-Name: 2adaee9aa90f280a406007695fbc4a314806584c93d6b62b46c031492b31ec27
This commit is contained in:
drh
2025-05-06 17:53:27 +00:00
parent ad39fa81af
commit 288f356854
4 changed files with 13 additions and 12 deletions

View File

@@ -3711,6 +3711,7 @@ case OP_MakeRecord: {
zHdr += sqlite3PutVarint(zHdr, serial_type);
if( pRec->n ){
assert( pRec->z!=0 );
assert( pRec->z!=(const char*)sqlite3CtypeMap );
memcpy(zPayload, pRec->z, pRec->n);
zPayload += pRec->n;
}