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

Fix off-by-one bug in [c3939d2491] uncovered by th3.

FossilOrigin-Name: 66f9faa9a969d004486ee38d492fb3eda6cdebab
This commit is contained in:
dan
2013-02-23 17:49:16 +00:00
parent bc1a3c6ce2
commit 87ade19eb9
3 changed files with 8 additions and 8 deletions

View File

@@ -5056,7 +5056,7 @@ static int allocateBtreePage(
if( eMode==BTALLOC_LE ){
for(i=0; i<k; i++){
iPage = get4byte(&aData[8+i*4]);
if( iPage<nearby ){
if( iPage<=nearby ){
closest = i;
break;
}