diff options
author | dwight <dwight@10gen.com> | 2011-07-19 13:32:03 -0400 |
---|---|---|
committer | dwight <dwight@10gen.com> | 2011-08-02 02:39:06 -0400 |
commit | 4d3fe8b73a889bc9604df9c9460a1165f6a7a211 (patch) | |
tree | 8cf8a1df4736ca50f1308eeb9f77869d0f3a36fc | |
parent | c716fa537d4e3df408175464dcd577529459e228 (diff) | |
download | mongo-4d3fe8b73a889bc9604df9c9460a1165f6a7a211.tar.gz |
elim a couple warnings on windows
-rw-r--r-- | db/dbcommands.cpp | 4 | ||||
-rwxr-xr-x | third_party/snappy/snappy.cc | 5 |
2 files changed, 7 insertions, 2 deletions
diff --git a/db/dbcommands.cpp b/db/dbcommands.cpp index cb75be0a732..6805bf5922f 100644 --- a/db/dbcommands.cpp +++ b/db/dbcommands.cpp @@ -272,10 +272,10 @@ namespace mongo { bool force = cmdObj.hasField("force") && cmdObj["force"].trueValue(); if (!force && theReplSet && theReplSet->isPrimary()) { - int timeout, now, start; + long long timeout, now, start; timeout = now = start = curTimeMicros64()/1000000; if (cmdObj.hasField("timeoutSecs")) { - timeout += cmdObj["timeoutSecs"].numberInt(); + timeout += cmdObj["timeoutSecs"].numberLong(); } OpTime lastOp = theReplSet->lastOpTimeWritten; diff --git a/third_party/snappy/snappy.cc b/third_party/snappy/snappy.cc index a591aba5945..fdc67e886c6 100755 --- a/third_party/snappy/snappy.cc +++ b/third_party/snappy/snappy.cc @@ -272,6 +272,11 @@ uint16* WorkingMemory::GetHashTable(size_t input_size, int* table_size) { } } // end namespace internal +#if defined(_WIN32) +// signed/unsigned mismatch +# pragma warning( disable : 4244 ) +#endif + // For 0 <= offset <= 4, GetUint32AtOffset(UNALIGNED_LOAD64(p), offset) will // equal UNALIGNED_LOAD32(p + offset). Motivation: On x86-64 hardware we have // empirically found that overlapping loads such as |