mirror of
https://github.com/sqlite/sqlite.git
synced 2024-12-01 17:23:42 +01:00
Make sure the database schema has been read before compiling an incrmental_vacuum pragma. (CVS 4032)
FossilOrigin-Name: efd7bcb34c1b4a0a3d4b954b90dfee93ac87bc86
This commit is contained in:
parent
89a4be8af1
commit
17a240a25e
14
manifest
14
manifest
@ -1,5 +1,5 @@
|
||||
C Fix\sa\sleaked\spage\sreference\sthat\scould\soccur\safter\san\sIO\serror\sin\sauto-vacuum\sdatabases.\sAlso\smodify\sincrvacuum.test\sto\swork\swith\sDEFAULT_AUTOVACUUM=1\sbuilds.\s(CVS\s4031)
|
||||
D 2007-05-23T13:34:32
|
||||
C Make\ssure\sthe\sdatabase\sschema\shas\sbeen\sread\sbefore\scompiling\san\sincrmental_vacuum\spragma.\s(CVS\s4032)
|
||||
D 2007-05-23T13:50:24
|
||||
F Makefile.in a42354804b50c2708ce72cf79e4daa30f50191b5
|
||||
F Makefile.linux-gcc 2d8574d1ba75f129aba2019f0b959db380a90935
|
||||
F README 9c4e2d6706bdcc3efdd773ce752a8cdab4f90028
|
||||
@ -96,7 +96,7 @@ F src/os_win.h 41a946bea10f61c158ce8645e7646b29d44f122b
|
||||
F src/pager.c acfa86f50b71b7e289508b213bb88e68273d42a0
|
||||
F src/pager.h 94110a5570dca30d54a883e880a3633b2e4c05ae
|
||||
F src/parse.y e276a0c35d6579938708f0842d0eba4e9b6866e6
|
||||
F src/pragma.c 6d5eb19feef9e84117b9b17a4c38b12b8c1c6897
|
||||
F src/pragma.c 0d25dad58bdfd6789943a10f1b9663c2eb85b96d
|
||||
F src/prepare.c 87c23644986b5e41a58bc76f05abebd899e00089
|
||||
F src/printf.c cd91e057fa7e2661673eecd4eeecf4900b1e5cfe
|
||||
F src/random.c 6119474a6f6917f708c1dee25b9a8e519a620e88
|
||||
@ -258,7 +258,7 @@ F test/in.test 369cb2aa1eab02296b4ec470732fe8c131260b1d
|
||||
F test/in2.test b1f447f4f0f67e9f83ff931e7e2e30873f9ea055
|
||||
F test/incrblob.test 7f82ae497364612aa17a37f77f12e01e2bee9f20
|
||||
F test/incrblob_err.test 2501bec57e317e7051451b5093b47fc61a96c85a
|
||||
F test/incrvacuum.test 0c88ba35bd6ba1ce2dc9ac953911481d2e626acc
|
||||
F test/incrvacuum.test 81de75c6178721a1fce9804a3a0509f5e7d8fa89
|
||||
F test/incrvacuum2.test 82397ceb5941cbe852fd29bb33fcdf5665bc80c2
|
||||
F test/incrvacuum_ioerr.test cb331403b8dea3c5bae6163861ff25037b0df56a
|
||||
F test/index.test e65df12bed94b2903ee89987115e1578687e9266
|
||||
@ -494,7 +494,7 @@ F www/tclsqlite.tcl bb0d1357328a42b1993d78573e587c6dcbc964b9
|
||||
F www/vdbe.tcl 87a31ace769f20d3627a64fa1fade7fed47b90d0
|
||||
F www/version3.tcl 890248cf7b70e60c383b0e84d77d5132b3ead42b
|
||||
F www/whentouse.tcl fc46eae081251c3c181bd79c5faef8195d7991a5
|
||||
P 10ee2d50cbcdcbbd8141ff2aba4fd2c0c0b70d67
|
||||
R e6f6e35a3430fe940ba19e54e2cd3045
|
||||
P e691f2fa3d8c1bbb66d27eea299ae2fb1ea1a16d
|
||||
R e2e7e92bcfd3231b45d0af23c2f65207
|
||||
U danielk1977
|
||||
Z 7dafc679264f64c59efbb8f3edda007b
|
||||
Z faab23a07e2c6de43bc46e141332808c
|
||||
|
@ -1 +1 @@
|
||||
e691f2fa3d8c1bbb66d27eea299ae2fb1ea1a16d
|
||||
efd7bcb34c1b4a0a3d4b954b90dfee93ac87bc86
|
@ -11,7 +11,7 @@
|
||||
*************************************************************************
|
||||
** This file contains code used to implement the PRAGMA command.
|
||||
**
|
||||
** $Id: pragma.c,v 1.138 2007/05/11 12:30:04 drh Exp $
|
||||
** $Id: pragma.c,v 1.139 2007/05/23 13:50:24 danielk1977 Exp $
|
||||
*/
|
||||
#include "sqliteInt.h"
|
||||
#include "os.h"
|
||||
@ -445,6 +445,9 @@ void sqlite3Pragma(
|
||||
#ifndef SQLITE_OMIT_AUTOVACUUM
|
||||
if( sqlite3StrICmp(zLeft,"incremental_vacuum")==0 ){
|
||||
int iLimit, addr;
|
||||
if( sqlite3ReadSchema(pParse) ){
|
||||
goto pragma_out;
|
||||
}
|
||||
if( zRight==0 || !sqlite3GetInt32(zRight, &iLimit) || iLimit<=0 ){
|
||||
iLimit = 0x7fffffff;
|
||||
}
|
||||
|
@ -14,7 +14,7 @@
|
||||
# Note: There are also some tests for incremental vacuum and IO
|
||||
# errors in incrvacuum_ioerr.test.
|
||||
#
|
||||
# $Id: incrvacuum.test,v 1.7 2007/05/23 13:34:32 danielk1977 Exp $
|
||||
# $Id: incrvacuum.test,v 1.8 2007/05/23 13:50:24 danielk1977 Exp $
|
||||
|
||||
set testdir [file dirname $argv0]
|
||||
source $testdir/tester.tcl
|
||||
@ -436,4 +436,20 @@ while 1 {
|
||||
incr ::iWrite
|
||||
}
|
||||
|
||||
#---------------------------------------------------------------------
|
||||
# This test - incrvacuum-8.* - is to check that nothing goes wrong
|
||||
# with an incremental-vacuum if it is the first statement executed
|
||||
# after an existing database is opened.
|
||||
#
|
||||
# At one point, this would always return SQLITE_SCHEMA (which
|
||||
# causes an infinite loop in tclsqlite.c if using the Tcl interface).
|
||||
#
|
||||
do_test incrvacuum-8.1 {
|
||||
db close
|
||||
sqlite3 db test.db
|
||||
execsql {
|
||||
PRAGMA incremental_vacuum(50);
|
||||
}
|
||||
} {}
|
||||
|
||||
finish_test
|
||||
|
Loading…
Reference in New Issue
Block a user