aboutsummaryrefslogtreecommitdiff
path: root/tool/fuzzershell.c
diff options
context:
space:
mode:
authordrh <drh@noemail.net>2015-04-25 16:39:49 +0000
committerdrh <drh@noemail.net>2015-04-25 16:39:49 +0000
commit7c84c02ce300758956c41c99fa978ce60cbfc4ac (patch)
tree576c0849e6175d6335f18b0e055890c0e538bcf2 /tool/fuzzershell.c
parentf332071b7f301910da51960b029e289c79a11ff3 (diff)
downloadsqlite-7c84c02ce300758956c41c99fa978ce60cbfc4ac.tar.gz
sqlite-7c84c02ce300758956c41c99fa978ce60cbfc4ac.zip
Fuzzershell: change the error summary output to work with releasetest.tcl.
Reduce the maximum number of OOM interations. FossilOrigin-Name: f5e6c4b28d25429aac53ea8cb334a2e6bd821f39
Diffstat (limited to 'tool/fuzzershell.c')
-rw-r--r--tool/fuzzershell.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/tool/fuzzershell.c b/tool/fuzzershell.c
index f2f493059..a464e6873 100644
--- a/tool/fuzzershell.c
+++ b/tool/fuzzershell.c
@@ -87,7 +87,7 @@ struct GlobalVars {
** Maximum number of iterations for an OOM test
*/
#ifndef OOM_MAX
-# define OOM_MAX 1000
+# define OOM_MAX 625
#endif
/*
@@ -734,8 +734,11 @@ int main(int argc, char **argv){
abendError("memory in use after close: %lld bytes", sqlite3_memory_used());
}
if( oomFlag ){
+ /* Limit the number of iterations of the OOM loop to OOM_MAX. If the
+ ** first pass (single failure) exceeds 2/3rds of OOM_MAX this skip the
+ ** second pass (continuous failure after first) completely. */
if( g.nOomFault==0 || oomCnt>OOM_MAX ){
- if( g.bOomOnce ){
+ if( g.bOomOnce && oomCnt<=(OOM_MAX*2/3) ){
oomCnt = g.iOomCntdown = 1;
g.bOomOnce = 0;
}else{
@@ -780,8 +783,8 @@ int main(int argc, char **argv){
}
if( !verboseFlag && multiTest && !quietFlag && !oomFlag ) printf("\n");
if( nTest>1 && !quietFlag ){
- printf("%d fuzz tests with no errors\nSQLite %s %s\n",
- nTest, sqlite3_libversion(), sqlite3_sourceid());
+ printf("%s: 0 errors out of %d tests\nSQLite %s %s\n",
+ g.zArgv0, nTest, sqlite3_libversion(), sqlite3_sourceid());
}
if( zDataOut ){
int n = 0;