diff options
author | Eliot Horowitz <eliot@10gen.com> | 2011-01-26 12:01:58 -0500 |
---|---|---|
committer | Eliot Horowitz <eliot@10gen.com> | 2011-01-26 12:01:58 -0500 |
commit | 440c54506b12cf6581b9d860a41a37c8afebc5ab (patch) | |
tree | 6376c5d257672735a0b67454e4587817b3d3712e | |
parent | d4c4acf737d55fc5e7008c056eafbe40dcbdcd48 (diff) | |
download | mongo-440c54506b12cf6581b9d860a41a37c8afebc5ab.tar.gz |
more debugging on win32
-rw-r--r-- | util/mmap_win.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/util/mmap_win.cpp b/util/mmap_win.cpp index b6301ce6aa5..19a5b1bbf7b 100644 --- a/util/mmap_win.cpp +++ b/util/mmap_win.cpp @@ -58,8 +58,12 @@ namespace mongo { void *p = MapViewOfFileEx(maphandle, FILE_MAP_COPY, 0, 0, /*dwNumberOfBytesToMap 0 means to eof*/0 /*len*/, oldPrivateAddr); - - assert(p); + + if ( p == 0 ) { + DWORD e = GetLastError(); + log() << "MapViewOfFileEx failed " << filename() << " " << errnoWithDescription(e) << endl; + assert(p); + } assert(p == oldPrivateAddr); return p; } |