Skip to content

Commit

Permalink
Initialize the mmap_limit of temporary files to the configured mmap_l…
Browse files Browse the repository at this point in the history
…imit.
  • Loading branch information
D. Richard Hipp committed Apr 3, 2013
1 parent f10b488 commit cf7ebf0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/os_unix.c
Original file line number Diff line number Diff line change
Expand Up @@ -5060,7 +5060,7 @@ static int fillInUnixFile(
pNew->pVfs = pVfs;
pNew->zPath = zFilename;
pNew->ctrlFlags = (u8)ctrlFlags;
pNew->mmapLimit = SQLITE_DEFAULT_MMAP_LIMIT;
pNew->mmapLimit = sqlite3GlobalConfig.mxMmap;
if( sqlite3_uri_boolean(((ctrlFlags & UNIXFILE_URI) ? zFilename : 0),
"psow", SQLITE_POWERSAFE_OVERWRITE) ){
pNew->ctrlFlags |= UNIXFILE_PSOW;
Expand Down
2 changes: 1 addition & 1 deletion src/os_win.c
Original file line number Diff line number Diff line change
Expand Up @@ -4116,7 +4116,7 @@ static int winOpen(
pFile->pMapRegion = 0;
pFile->mmapSize = 0;
pFile->mmapOrigsize = 0;
pFile->mmapLimit = SQLITE_DEFAULT_MMAP_LIMIT;
pFile->mmapLimit = sqlite3GlobalConfig.mxMmap;

OpenCounter(+1);
return rc;
Expand Down

0 comments on commit cf7ebf0

Please sign in to comment.