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

Add the SQLITE_CONFIG_MMAP_LIMIT configuration option for overriding the

SQLITE_DEFAULT_MMAP_LIMIT compile-time setting.  Enhance "PRAGMA mmap_limit"
so that without a specific database name, it sets the limit on all database
files and changes the default for any future databases that might be added
using ATTACH.

FossilOrigin-Name: 78141d0a16dd1d56b575fccd149de7fa789cb06c
This commit is contained in:
drh
2013-04-01 22:38:06 +00:00
parent a539c8a464
commit a1f42c7c32
10 changed files with 53 additions and 17 deletions

View File

@@ -3711,6 +3711,7 @@ static int unixFileControl(sqlite3_file *id, int op, void *pArg){
}
case SQLITE_FCNTL_MMAP_LIMIT: {
pFile->mmapLimit = *(i64*)pArg;
printf("MMAP-LIMIT(%s) -> %lld\n", pFile->zPath, pFile->mmapLimit);
return SQLITE_OK;
}
#ifdef SQLITE_DEBUG