diff options
author | drh <drh@noemail.net> | 2011-12-20 13:13:09 +0000 |
---|---|---|
committer | drh <drh@noemail.net> | 2011-12-20 13:13:09 +0000 |
commit | 4120994fdf0b646fda4768b68dda16f0799fd0ff (patch) | |
tree | 00488301268be216497da2a992e40d435dd36454 /src | |
parent | 19969d96ce107f6e9bbbd8af83288f151299b517 (diff) | |
download | sqlite-4120994fdf0b646fda4768b68dda16f0799fd0ff.tar.gz sqlite-4120994fdf0b646fda4768b68dda16f0799fd0ff.zip |
Assert that the isCommit parameter to sqlite3WalFrames() is zero if and
only if the nTruncate parameter is zero.
FossilOrigin-Name: 979daf92e09305665d943e197b93b81139197c5b
Diffstat (limited to 'src')
-rw-r--r-- | src/wal.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -2691,6 +2691,10 @@ int sqlite3WalFrames( assert( pList ); assert( pWal->writeLock ); + /* If this frame set completes a transaction, then nTruncate>0. If + ** nTruncate==0 then this frame set does not complete the transaction. */ + assert( (isCommit!=0)==(nTruncate!=0) ); + #if defined(SQLITE_TEST) && defined(SQLITE_DEBUG) { int cnt; for(cnt=0, p=pList; p; p=p->pDirty, cnt++){} WALTRACE(("WAL%p: frame write begin. %d frames. mxFrame=%d. %s\n", |