SQLite

Check-in [fdd44bbb50]
Login

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

Overview
Comment:Add an assert() to the code on this branch.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | reuse-schema
Files: files | file ages | folders
SHA3-256: fdd44bbb501c7252097e79685e916e760846e183bc9f022f9cf32f1d32f0089d
User & Date: dan 2019-08-06 11:45:33.654
Context
2019-08-06
15:02
Add a multi-threaded test to threadtest3.c for the feature on this branch. (check-in: 62557fab0d user: dan tags: reuse-schema)
11:45
Add an assert() to the code on this branch. (check-in: fdd44bbb50 user: dan tags: reuse-schema)
2019-07-26
20:54
Merge latest changes from trunk into this branch. (check-in: 7f1e4e4b99 user: dan tags: reuse-schema)
Changes
Unified Diff Ignore Whitespace Patch
Changes to src/callback.c.
608
609
610
611
612
613
614

615
616
617
618
619
620
621
** This function returns the Schema object to the schema-pool and sets
** Db.pSchema to point to the schema-pool's static, empty, Schema object.
*/
static void schemaRelease(sqlite3 *db, Db *pDb){
  Schema *pRelease = pDb->pSchema;
  SchemaPool *pSPool = pDb->pSPool;


  pDb->pSchema = &pSPool->sSchema;

  assert( pDb->pSPool && pRelease );
  assert( pRelease->schemaFlags & DB_SchemaLoaded );
  assert( (pDb->pSchema->schemaFlags & DB_SchemaLoaded)==0 );
  assert( sqlite3_mutex_held(sqlite3_mutex_alloc(SQLITE_MUTEX_STATIC_MASTER)) );








>







608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
** This function returns the Schema object to the schema-pool and sets
** Db.pSchema to point to the schema-pool's static, empty, Schema object.
*/
static void schemaRelease(sqlite3 *db, Db *pDb){
  Schema *pRelease = pDb->pSchema;
  SchemaPool *pSPool = pDb->pSPool;

  assert( pDb->pSchema->iGeneration==pSPool->sSchema.iGeneration );
  pDb->pSchema = &pSPool->sSchema;

  assert( pDb->pSPool && pRelease );
  assert( pRelease->schemaFlags & DB_SchemaLoaded );
  assert( (pDb->pSchema->schemaFlags & DB_SchemaLoaded)==0 );
  assert( sqlite3_mutex_held(sqlite3_mutex_alloc(SQLITE_MUTEX_STATIC_MASTER)) );