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

Fix a page reference leak that could occur after an IO error. (CVS 4036)

FossilOrigin-Name: d00c8242c610476c15d6eb4dc53fecab3971fea1
This commit is contained in:
danielk1977
2007-05-24 09:20:16 +00:00
parent d3a29ce7dc
commit deb403e797
3 changed files with 11 additions and 11 deletions

View File

@@ -1,5 +1,5 @@
C Remove\san\sincorrect\sassert()\sstatement\sthat\swas\sbeing\striggered\sby\sioerr\stests\srun\sin\sutf-16\smode.\s(CVS\s4035) C Fix\sa\spage\sreference\sleak\sthat\scould\soccur\safter\san\sIO\serror.\s(CVS\s4036)
D 2007-05-24T07:47:07 D 2007-05-24T09:20:16
F Makefile.in a42354804b50c2708ce72cf79e4daa30f50191b5 F Makefile.in a42354804b50c2708ce72cf79e4daa30f50191b5
F Makefile.linux-gcc 2d8574d1ba75f129aba2019f0b959db380a90935 F Makefile.linux-gcc 2d8574d1ba75f129aba2019f0b959db380a90935
F README 9c4e2d6706bdcc3efdd773ce752a8cdab4f90028 F README 9c4e2d6706bdcc3efdd773ce752a8cdab4f90028
@@ -62,7 +62,7 @@ F src/alter.c 1b1deeb97446ed87f2fa17a3eb6236548841a348
F src/analyze.c e8fcb1c35ace8418615eb18d9601f321ac86b2ec F src/analyze.c e8fcb1c35ace8418615eb18d9601f321ac86b2ec
F src/attach.c ba628db0c2b6a362f036d017bf1196cdfe4ebb37 F src/attach.c ba628db0c2b6a362f036d017bf1196cdfe4ebb37
F src/auth.c 5ea90bc93dfea46e9fe4bf531e14c7cd98219ecb F src/auth.c 5ea90bc93dfea46e9fe4bf531e14c7cd98219ecb
F src/btree.c f28399255953e789f6e10f2ac378aaeacd07be54 F src/btree.c bde03df933f8295e984b831779a318cc7c38f339
F src/btree.h 1d527bf61ed176f980c34999d5793a0fd45dcf8c F src/btree.h 1d527bf61ed176f980c34999d5793a0fd45dcf8c
F src/btreeInt.h f92c0577f49d961c0148b477a25647e8fd80eecf F src/btreeInt.h f92c0577f49d961c0148b477a25647e8fd80eecf
F src/build.c 50992d92e131a9aa9aa6657fb1ddc13e176fd70c F src/build.c 50992d92e131a9aa9aa6657fb1ddc13e176fd70c
@@ -494,7 +494,7 @@ F www/tclsqlite.tcl bb0d1357328a42b1993d78573e587c6dcbc964b9
F www/vdbe.tcl 87a31ace769f20d3627a64fa1fade7fed47b90d0 F www/vdbe.tcl 87a31ace769f20d3627a64fa1fade7fed47b90d0
F www/version3.tcl 890248cf7b70e60c383b0e84d77d5132b3ead42b F www/version3.tcl 890248cf7b70e60c383b0e84d77d5132b3ead42b
F www/whentouse.tcl fc46eae081251c3c181bd79c5faef8195d7991a5 F www/whentouse.tcl fc46eae081251c3c181bd79c5faef8195d7991a5
P 3c54cddf23e3b9f62815d1b825110563f78cc325 P c6575173be13296fbe57932f2d24a568f6d552ff
R daeeb60ad754898cfa2fa94c3fe97378 R baefc7d51c05b37700d6c36d25807fe6
U danielk1977 U danielk1977
Z bd68142b41ddc6ade1830ed22b5c15df Z 4631c8b4d947d8c5bb83b93a6f0ce1c2

View File

@@ -1 +1 @@
c6575173be13296fbe57932f2d24a568f6d552ff d00c8242c610476c15d6eb4dc53fecab3971fea1

View File

@@ -9,7 +9,7 @@
** May you share freely, never taking more than you give. ** May you share freely, never taking more than you give.
** **
************************************************************************* *************************************************************************
** $Id: btree.c,v 1.387 2007/05/24 07:47:07 danielk1977 Exp $ ** $Id: btree.c,v 1.388 2007/05/24 09:20:16 danielk1977 Exp $
** **
** This file implements a external (disk-based) database using BTrees. ** This file implements a external (disk-based) database using BTrees.
** See the header comment on "btreeInt.h" for additional information. ** See the header comment on "btreeInt.h" for additional information.
@@ -4244,11 +4244,11 @@ static int balance_quick(MemPage *pPage, MemPage *pParent){
*/ */
if( pBt->autoVacuum ){ if( pBt->autoVacuum ){
rc = ptrmapPut(pBt, pgnoNew, PTRMAP_BTREE, pParent->pgno); rc = ptrmapPut(pBt, pgnoNew, PTRMAP_BTREE, pParent->pgno);
if( rc!=SQLITE_OK ){ if( rc==SQLITE_OK ){
return rc; rc = ptrmapPutOvfl(pNew, 0);
} }
rc = ptrmapPutOvfl(pNew, 0);
if( rc!=SQLITE_OK ){ if( rc!=SQLITE_OK ){
releasePage(pNew);
return rc; return rc;
} }
} }