-C Use\sthe\spadding\sword\sin\sthe\sMem\sobject\sas\stemporary\sstorage\sfor\nserial_type\svalue\sin\sOP_Record,\sand\sthus\savoid\sa\sredundant\scomputation\sof\nthe\sserial_type\sfor\seach\scolumn.
-D 2014-10-13T20:12:47.457
+C Optimize\sa\sdatabase\scorruption\stest\sinside\sof\sthe\sOP_Column\sopcode.
+D 2014-10-13T23:39:02.463
F Makefile.arm-wince-mingw32ce-gcc d6df77f1f48d690bd73162294bbba7f59507c72f
F Makefile.in cf57f673d77606ab0f2d9627ca52a9ba1464146a
F Makefile.linux-gcc 91d710bdc4998cb015f39edf3cb314ec4f4d7e23
F src/utf.c fc6b889ba0779b7722634cdeaa25f1930d93820c
F src/util.c 4006c01772bd8d8ac4306d523bbcee41d3e392d8
F src/vacuum.c 59f03f92bcff57faa6a8ca256eb29ccddfb0614a
-F src/vdbe.c 8755e3bb0d7d26b2b156c6f29ddd6b3d32b77df2
+F src/vdbe.c 5ee15a66ce07e0482b92aa29e4dd0c5827a22d79
F src/vdbe.h 09f5b4e3719fa454f252322b1cdab5cf1f361327
F src/vdbeInt.h e2a060a55ee18a6ab973353a5e2ec7ee569bf787
F src/vdbeapi.c 37a6c6ae284a97bcace365f2f0a225680c0499d9
F tool/warnings-clang.sh f6aa929dc20ef1f856af04a730772f59283631d4
F tool/warnings.sh 0abfd78ceb09b7f7c27c688c8e3fe93268a13b32
F tool/win/sqlite.vsix deb315d026cc8400325c5863eef847784a219a2f
-P 04892f8ba6c55cec4fe37bfe59b6349fd2a40698
-R b0e17ef60b5aa0edd0fe18cf5fe3de58
+P 4b3b65ee5ea61e9b9671ca027940bf02689cb890
+R 42e26b1c48be06a100ad5530a5448c12
U drh
-Z 6462e46ba313ee1bcf094c3a26197f24
+Z 6b074ae9a762ef61cbe684b68fc815ba
sMem.flags = MEM_Null;
}
- /* If we have read more header data than was contained in the header,
- ** or if the end of the last field appears to be past the end of the
- ** record, or if the end of the last field appears to be before the end
- ** of the record (when all fields present), then we must be dealing
- ** with a corrupt database.
+ /* The record is corrupt if any of the following are true:
+ ** (1) the bytes of the header extend past the declared header size
+ ** (zHdr>zEndHdr)
+ ** (2) the entire header was used but not all data was used
+ ** (zHdr==zEndHdr && offset!=pC->payloadSize)
+ ** (3) the end of the data extends beyond the end of the record.
+ ** (offset > pC->payloadSize)
*/
- if( (zHdr > zEndHdr)
+ if( (zHdr>=zEndHdr && (zHdr>zEndHdr || offset!=pC->payloadSize))
|| (offset > pC->payloadSize)
- || (zHdr==zEndHdr && offset!=pC->payloadSize)
){
rc = SQLITE_CORRUPT_BKPT;
goto op_column_error;