/ Check-in [20d7b294]
Login
SQLite training in Houston TX on 2019-11-05 (details)
Part of the 2019 Tcl Conference

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

Overview
Comment:Fix a bug in the handling of I/O errors introduced by the addition of extended error codes in check-in (3422). (CVS 3438)
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 20d7b29443ea7d9ec1ef81219c74ba725e8711e3
User & Date: drh 2006-09-23 21:44:24
Context
2006-09-25
13:09
Remove legacy cruft from shell.c. (CVS 3439) check-in: 815d8f84 user: drh tags: trunk
2006-09-23
21:44
Fix a bug in the handling of I/O errors introduced by the addition of extended error codes in check-in (3422). (CVS 3438) check-in: 20d7b294 user: drh tags: trunk
20:46
Fix documentation typo. Ticket #1986 (CVS 3437) check-in: 58c32ce3 user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/vdbeaux.c.

  1285   1285       return SQLITE_OK;
  1286   1286     }
  1287   1287     closeAllCursors(p);
  1288   1288     checkActiveVdbeCnt(db);
  1289   1289   
  1290   1290     /* No commit or rollback needed if the program never started */
  1291   1291     if( p->pc>=0 ){
  1292         -
         1292  +    int mrc;   /* Primary error code from p->rc */
  1293   1293       /* Check for one of the special errors - SQLITE_NOMEM or SQLITE_IOERR */
  1294         -    isSpecialError = ((p->rc==SQLITE_NOMEM || p->rc==SQLITE_IOERR)?1:0);
         1294  +    mrc = p->rc & 0xff;
         1295  +    isSpecialError = ((mrc==SQLITE_NOMEM || mrc==SQLITE_IOERR)?1:0);
  1295   1296       if( isSpecialError ){
  1296   1297         /* This loop does static analysis of the query to see which of the
  1297   1298         ** following three categories it falls into:
  1298   1299         **
  1299   1300         **     Read-only
  1300   1301         **     Query with statement journal
  1301   1302         **     Query without statement journal