diff --git a/source/libs/tdb/src/db/tdbBtree.c b/source/libs/tdb/src/db/tdbBtree.c index 4169509280..670cdc002a 100644 --- a/source/libs/tdb/src/db/tdbBtree.c +++ b/source/libs/tdb/src/db/tdbBtree.c @@ -711,7 +711,16 @@ static int tdbBtreeBalanceNonRoot(SBTree *pBt, SPage *pParent, int idx) { } } - // Loop to make the distribution even + nNews = nNews + 1; + + // back loop to make the distribution even + for (int iNew = nNews - 1; iNew > 0; iNew--) { + /* code */ + } + } + + SPage *pNews[5]; + { // Allocate the new pages } #if 0