Add another boundary-condition testcase() macro to btree.c. Correct the

comment on modifyPagePointer(). (CVS 6863)

FossilOrigin-Name: fed66e8695ee552d5ca05ac91485cfc5940e7496
This commit is contained in:
drh 2009-07-08 18:12:49 +00:00
parent b908d76fb8
commit f3aed5944c
3 changed files with 12 additions and 12 deletions

View File

@ -1,5 +1,5 @@
C Improvements\sto\scomments\sin\sbtree.c:freeSpace().\s\sAdded\sa\stestcase()\smacro\nto\sverify\sa\sboundary\scase\sis\stested\sin\ssqlite3BtreeInitPage().\s(CVS\s6862)
D 2009-07-08T16:54:40
C Add\sanother\sboundary-condition\stestcase()\smacro\sto\sbtree.c.\s\sCorrect\sthe\ncomment\son\smodifyPagePointer().\s(CVS\s6863)
D 2009-07-08T18:12:49
F Makefile.arm-wince-mingw32ce-gcc fcd5e9cd67fe88836360bb4f9ef4cb7f8e2fb5a0
F Makefile.in df9359da7a726ccb67a45db905c5447d5c00c6ef
F Makefile.linux-gcc d53183f4aa6a9192d249731c90dbdffbd2c68654
@ -106,7 +106,7 @@ F src/auth.c 802a9439dfa0b8c208b10055cba400e82ef18025
F src/backup.c 6f1c2d9862c8a3feb7739dfcca02c1f5352e37f3
F src/bitvec.c 0ef0651714728055d43de7a4cdd95e703fac0119
F src/btmutex.c 9b899c0d8df3bd68f527b0afe03088321b696d3c
F src/btree.c 88efb67b8816b6e773cfc824916a4a1df1178715
F src/btree.c a2117e0dde3eeb5845b3a6f56bfed2255e3eefdb
F src/btree.h e761619e76a1125d2d82bd3613b5a7ac7d1ee6f7
F src/btreeInt.h b31e5ac04181c7e2892c33ab06228c551df6233c
F src/build.c 867028ee9f63f7bc8eb8d4a720bb98cf9b9a12b4
@ -740,7 +740,7 @@ F tool/speedtest2.tcl ee2149167303ba8e95af97873c575c3e0fab58ff
F tool/speedtest8.c 2902c46588c40b55661e471d7a86e4dd71a18224
F tool/speedtest8inst1.c 293327bc76823f473684d589a8160bde1f52c14e
F tool/vdbe-compress.tcl 672f81d693a03f80f5ae60bfefacd8a349e76746
P 196cbf82290a308e78b13044d0fae993f2d5cb90
R a273a9df3f7120ba57b67913a5610fd6
P 5ac991b3cea214095b8369e85f3e0ad8e5059ad6
R ca47272c465be8241f9f27fe855a504a
U drh
Z b118b571b45c65757687df0def85d091
Z b7a8ccb171b7c92d55cc6ecbc4d9687d

View File

@ -1 +1 @@
5ac991b3cea214095b8369e85f3e0ad8e5059ad6
fed66e8695ee552d5ca05ac91485cfc5940e7496

View File

@ -9,7 +9,7 @@
** May you share freely, never taking more than you give.
**
*************************************************************************
** $Id: btree.c,v 1.662 2009/07/08 16:54:40 drh Exp $
** $Id: btree.c,v 1.663 2009/07/08 18:12:49 drh Exp $
**
** This file implements a external (disk-based) database using BTrees.
** See the header comment on "btreeInt.h" for additional information.
@ -1549,6 +1549,7 @@ static int getAndInitPage(
rc = SQLITE_OK;
}else{
/* Page not in cache. Acquire it. */
testcase( pgno==pagerPagecount(pBt) );
if( pgno>pagerPagecount(pBt) ){
return SQLITE_CORRUPT_BKPT;
}
@ -2545,10 +2546,9 @@ set_child_ptrmaps_out:
}
/*
** Somewhere on pPage, which is guaranteed to be a btree page, not an overflow
** page, is a pointer to page iFrom. Modify this pointer so that it points to
** iTo. Parameter eType describes the type of pointer to be modified, as
** follows:
** Somewhere on pPage is a pointer to page iFrom. Modify this pointer so
** that it points to iTo. Parameter eType describes the type of pointer to
** be modified, as follows:
**
** PTRMAP_BTREE: pPage is a btree-page. The pointer points at a child
** page of pPage.