aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authordrh <drh@noemail.net>2012-04-16 17:22:30 +0000
committerdrh <drh@noemail.net>2012-04-16 17:22:30 +0000
commit8c5058bbdb96a4e9a0392011ad0aa279d1a32e8b (patch)
tree30fa5e67a0e0bc3389bdb17d3728cdb40ed1e356 /src
parent5adc60bab065f318044ada7d4249f25a53e9cb9e (diff)
downloadsqlite-8c5058bbdb96a4e9a0392011ad0aa279d1a32e8b.tar.gz
sqlite-8c5058bbdb96a4e9a0392011ad0aa279d1a32e8b.zip
Fix a bug in the command-line shell logic that attempts to continue with a
".dump" even after encountering database corruption. FossilOrigin-Name: 020b5e90f950a42299074ff770612b9e68850d95
Diffstat (limited to 'src')
-rw-r--r--src/shell.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/shell.c b/src/shell.c
index e5cfec70a..b4c21ad38 100644
--- a/src/shell.c
+++ b/src/shell.c
@@ -1369,7 +1369,7 @@ static int run_schema_dump_query(
}
zQ2 = malloc( len+100 );
if( zQ2==0 ) return rc;
- sqlite3_snprintf(sizeof(zQ2), zQ2, "%s ORDER BY rowid DESC", zQuery);
+ sqlite3_snprintf(len+100, zQ2, "%s ORDER BY rowid DESC", zQuery);
rc = sqlite3_exec(p->db, zQ2, dump_callback, p, &zErr);
if( rc ){
fprintf(p->out, "/****** ERROR: %s ******/\n", zErr);