diff options
author | Keith Bostic <keith@wiredtiger.com> | 2013-03-06 11:10:37 -0500 |
---|---|---|
committer | Keith Bostic <keith@wiredtiger.com> | 2013-03-06 11:10:37 -0500 |
commit | 986fe36ea13344b906dc1aa1260a0986ede6d999 (patch) | |
tree | f59404f2bbcdc17086bc15f3e21c38b1537b0cba /src | |
parent | 0f392f6581fa36c3ae50d143505e8e90e3641a78 (diff) | |
download | mongo-986fe36ea13344b906dc1aa1260a0986ede6d999.tar.gz |
Turn of file-mapping if the application configured a cache-size maximum.
Diffstat (limited to 'src')
-rw-r--r-- | src/block/block_map.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/block/block_map.c b/src/block/block_map.c index 202a6a00746..93dcc4bec6c 100644 --- a/src/block/block_map.c +++ b/src/block/block_map.c @@ -35,6 +35,13 @@ __wt_block_map( return (0); /* + * Turn off mapping if the application configured a cache size maximum, + * we can't control how much of the cache size we use in that case. + */ + if (block->os_cache_max != 0) + return (0); + + /* * Map the file into memory. * Ignore errors, we'll read the file through the cache if map fails. */ |