mirror of
https://github.com/mongodb/mongo.git
synced 2024-12-01 09:32:32 +01:00
hack namespace _hudsonSmall which uses small files so we can test file boundaries
This commit is contained in:
parent
fa1bbbc78a
commit
517956ab60
@ -455,7 +455,18 @@ void PhysicalDataFile::open(int fn, const char *filename) {
|
||||
} else
|
||||
length = 0x7ff00000;
|
||||
|
||||
assert( length >= 64*1024*1024 && length % 4096 == 0 );
|
||||
assert( length >= 64*1024*1024 );
|
||||
|
||||
if( strstr(filename, "_hudsonSmall") ) {
|
||||
int mult = 1;
|
||||
if ( fn > 1 && fn < 1000 )
|
||||
mult = fn;
|
||||
length = 1024 * 512 * mult;
|
||||
cout << "Warning : using small files for _hudsonSmall" << endl;
|
||||
}
|
||||
|
||||
|
||||
assert( length % 4096 == 0 );
|
||||
|
||||
assert(fn == fileNo);
|
||||
header = (PDFHeader *) mmf.map(filename, length);
|
||||
|
Loading…
Reference in New Issue
Block a user