summaryrefslogtreecommitdiff
path: root/util/version.cpp
diff options
context:
space:
mode:
authorEliot Horowitz <eliot@10gen.com>2011-09-26 00:36:01 -0400
committerEliot Horowitz <eliot@10gen.com>2011-09-26 02:42:34 -0400
commitca86100b8a62ea86ab39f49ea235b6b9dd19bbad (patch)
treeee2801c7fc61c98f20a4bd454602464de06d0ce7 /util/version.cpp
parentb09007c96bafb185374ccd5ab68fba5e8362017f (diff)
downloadmongo-ca86100b8a62ea86ab39f49ea235b6b9dd19bbad.tar.gz
paranoid compiler fix
Diffstat (limited to 'util/version.cpp')
-rw-r--r--util/version.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/util/version.cpp b/util/version.cpp
index c49288a1aed..2001a5116e4 100644
--- a/util/version.cpp
+++ b/util/version.cpp
@@ -112,7 +112,7 @@ namespace mongo {
f.open("/proc/self/numa_maps", /*read_only*/true);
if ( f.is_open() && ! f.bad() ) {
char line[100]; //we only need the first line
- read(f.fd, line, sizeof(line));
+ assert( read(f.fd, line, sizeof(line)) <= 100 );
// just in case...
line[98] = ' ';