1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-15 11:41:13 +03:00

Added SQLITE_OPEN_SHAREDCACHE and SQLITE_OPEN_PRIVATECACHE flags as

possibilities to sqlite3_open_v2(), to override the global shared
cache mode setting.  Ticket [9fd0bc36639c15]

FossilOrigin-Name: f509eb8b488bb39deda4ca88f66ed40c6784af02
This commit is contained in:
drh
2009-09-09 14:17:52 +00:00
parent 643a392270
commit f1f12688d8
6 changed files with 35 additions and 17 deletions

View File

@@ -1544,6 +1544,11 @@ static int openDatabase(
}else{
isThreadsafe = sqlite3GlobalConfig.bFullMutex;
}
if( flags & SQLITE_OPEN_PRIVATECACHE ){
flags &= SQLITE_OPEN_SHAREDCACHE;
}else if( sqlite3GlobalConfig.sharedCacheEnabled ){
flags |= SQLITE_OPEN_SHAREDCACHE;
}
/* Remove harmful bits from the flags parameter
**