/ Check-in [3e15dea5]
Login

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

Overview
Comment:This condition was not always true after all.....

Change an always-true condition in the virtual table transaction interface into an assert().

Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | mistake
Files: files | file ages | folders
SHA1: 3e15dea55c31c92b305fdba23e3f6e8f97bd369d
User & Date: drh 2015-09-29 17:51:30
Original Comment: Change an always-true condition in the virtual table transaction interface into an assert().
Context
2015-09-29
17:51
This condition was not always true after all.....

Change an always-true condition in the virtual table transaction interface into an assert(). Closed-Leaf check-in: 3e15dea5 user: drh tags: mistake

17:20
Use symbolic names XN_ROWID and XN_EXPR in place of the (-1) and (-2) magic numbers in Index.aiColumn[]. Add asserts to help verify that Index.aiColumn[] is always used correctly. Fix one place in FK processing where Index.aiColumn[] was not being used correctly. check-in: 7d272aa6 user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/vtab.c.

   981    981             case SAVEPOINT_ROLLBACK:
   982    982               xMethod = pMod->xRollbackTo;
   983    983               break;
   984    984             default:
   985    985               xMethod = pMod->xRelease;
   986    986               break;
   987    987           }
   988         -        if( xMethod && pVTab->iSavepoint>iSavepoint ){
          988  +        assert( pVTab->iSavepoint > iSavepoint );
          989  +        if( xMethod ){
   989    990             rc = xMethod(pVTab->pVtab, iSavepoint);
   990    991           }
   991    992         }
   992    993       }
   993    994     }
   994    995     return rc;
   995    996   }