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

Size reduction and performance increase in the pageFindSlot() routine of

btree.c.

FossilOrigin-Name: 5d247e38560b97975568e8a48324acaca1002ec2ef7fa3efc9c8aa7d83412aad
This commit is contained in:
drh
2022-07-07 20:29:49 +00:00
parent dce232a298
commit ebaa9477d7
3 changed files with 9 additions and 9 deletions

View File

@@ -1673,9 +1673,9 @@ static u8 *pageFindSlot(MemPage *pPg, int nByte, int *pRc){
iAddr = pc;
pTmp = &aData[pc];
pc = get2byte(pTmp);
if( pc<=iAddr+size ){
if( pc<=iAddr ){
if( pc ){
/* The next slot in the chain is not past the end of the current slot */
/* The next slot in the chain comes before the current slot */
*pRc = SQLITE_CORRUPT_PAGE(pPg);
}
return 0;