1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-08-05 15:55:57 +03:00

Remove a "harmless()" macro that is no longer relevant.

FossilOrigin-Name: 87c357c60168fdc52c82382aa7288d66886f5fbe2ae6af68344dbcfdbca9069b
This commit is contained in:
drh
2021-10-08 18:12:37 +00:00
parent 635e6a92a0
commit 15b5411a67
3 changed files with 7 additions and 17 deletions

View File

@@ -5871,16 +5871,6 @@ static SQLITE_NOINLINE int btreeNext(BtCursor *pCur){
return SQLITE_CORRUPT_BKPT;
}
/* If the database file is corrupt, it is possible for the value of idx
** to be invalid here. This can only occur if a second cursor modifies
** the page while cursor pCur is holding a reference to it. Which can
** only happen if the database is corrupt in such a way as to link the
** page into more than one b-tree structure.
**
** Update 2019-12-23: appears to long longer be possible after the
** addition of anotherValidCursor() condition on balance_deeper(). */
harmless( idx>pPage->nCell );
if( idx>=pPage->nCell ){
if( !pPage->leaf ){
rc = moveToChild(pCur, get4byte(&pPage->aData[pPage->hdrOffset+8]));