summaryrefslogtreecommitdiff
path: root/src/mongo/util
diff options
context:
space:
mode:
authorTad Marshall <tad@10gen.com>2012-03-03 17:40:31 -0500
committerTad Marshall <tad@10gen.com>2012-03-03 17:40:31 -0500
commitf1bfa9d78159f576f4dc43137f205eb82ba5a9f4 (patch)
tree521b6723f1f95649baa6ffa7b78063282e5d1ee6 /src/mongo/util
parent915ef6cd2ef940ccb263d697b71ccf770dfda189 (diff)
downloadmongo-f1bfa9d78159f576f4dc43137f205eb82ba5a9f4.tar.gz
SERVER-4615 Fix memory in Windows hostInfo()
Set dwLength to the size of the MEMORYSTATUSEX struct before passing it it GlobalMemoryStatusEx().
Diffstat (limited to 'src/mongo/util')
-rwxr-xr-xsrc/mongo/util/processinfo_win32.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/mongo/util/processinfo_win32.cpp b/src/mongo/util/processinfo_win32.cpp
index 88e61b74851..79550b44bfb 100755
--- a/src/mongo/util/processinfo_win32.cpp
+++ b/src/mongo/util/processinfo_win32.cpp
@@ -109,6 +109,7 @@ namespace mongo {
bExtra.append( "pageSize", static_cast< int >(ntsysinfo.dwPageSize) );
// get memory info
+ mse.dwLength = sizeof( mse );
if ( GlobalMemoryStatusEx( &mse ) ) {
memSize = mse.ullTotalPhys;
}