summaryrefslogtreecommitdiff
path: root/src/mongo/bson/bsonelement.cpp
diff options
context:
space:
mode:
authorGeert Bosch <geert@mongodb.com>2015-10-29 09:33:26 -0400
committerGeert Bosch <geert@mongodb.com>2015-10-29 09:33:26 -0400
commit4aa1aa00f4f19921101c2ed540247f06f00e21ea (patch)
treea3e8d488fdccdf84ae0d845bdb2b6a4809e5d68e /src/mongo/bson/bsonelement.cpp
parentadcef363bccdb179e448b47e18ba5541d9a60eab (diff)
downloadmongo-4aa1aa00f4f19921101c2ed540247f06f00e21ea.tar.gz
Revert "SERVER-21160: revert woCompare to using unsigned comparison for Timestamp"
This reverts commit adcef363bccdb179e448b47e18ba5541d9a60eab.
Diffstat (limited to 'src/mongo/bson/bsonelement.cpp')
-rw-r--r--src/mongo/bson/bsonelement.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mongo/bson/bsonelement.cpp b/src/mongo/bson/bsonelement.cpp
index 5eb40a6bd73..f728998d62c 100644
--- a/src/mongo/bson/bsonelement.cpp
+++ b/src/mongo/bson/bsonelement.cpp
@@ -867,9 +867,9 @@ int compareElementValues(const BSONElement& l, const BSONElement& r) {
case bsonTimestamp:
// unsigned compare for timestamps - note they are not really dates but (ordinal +
// time_t)
- if (l.timestamp() < r.timestamp())
+ if (l.date() < r.date())
return -1;
- return l.timestamp() == r.timestamp() ? 0 : 1;
+ return l.date() == r.date() ? 0 : 1;
case Date:
// Signed comparisons for Dates.
{