/ Check-in [6f3dad32]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Change a testcase() added by the previous checkin into an assert().
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 6f3dad32aa0e1e9ee374302c82bea9bd60d5854b
User & Date: drh 2011-02-19 17:02:44
Context
2011-02-19
23:18
An SQLITE_PROTOCOL error counts as a locking error for verification purposes. check-in: e87d499a user: drh tags: trunk
17:02
Change a testcase() added by the previous checkin into an assert(). check-in: 6f3dad32 user: drh tags: trunk
16:51
Add testcase macros to verify that all return values from walTryBeginRead() are tested. check-in: 262b6fca user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/wal.c.

  2536   2536       walUnlockShared(pWal, WAL_READ_LOCK(0));
  2537   2537       pWal->readLock = -1;
  2538   2538       cnt = 0;
  2539   2539       do{
  2540   2540         int notUsed;
  2541   2541         rc = walTryBeginRead(pWal, &notUsed, 1, ++cnt);
  2542   2542       }while( rc==WAL_RETRY );
  2543         -    testcase( (rc&0xff)==SQLITE_BUSY );
         2543  +    assert( (rc&0xff)!=SQLITE_BUSY ); /* BUSY not possible when useWal==1 */
  2544   2544       testcase( (rc&0xff)==SQLITE_IOERR );
  2545   2545       testcase( rc==SQLITE_PROTOCOL );
  2546   2546       testcase( rc==SQLITE_OK );
  2547   2547     }
  2548   2548     return rc;
  2549   2549   }
  2550   2550