Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 16 May 2014 07:58:04 +0000 (UTC)
From:      Alex Dupre <ale@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r354198 - head/databases/mongodb/files
Message-ID:  <201405160758.s4G7w4aT094466@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: ale
Date: Fri May 16 07:58:04 2014
New Revision: 354198
URL: http://svnweb.freebsd.org/changeset/ports/354198
QAT: https://qat.redports.org/buildarchive/r354198/

Log:
  Fix build on 32-bit archs.

Added:
  head/databases/mongodb/files/patch-src_mongo_db_kill_current_op.cpp   (contents, props changed)
  head/databases/mongodb/files/patch-src_mongo_db_ops_modifier_push.cpp   (contents, props changed)

Added: head/databases/mongodb/files/patch-src_mongo_db_kill_current_op.cpp
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/databases/mongodb/files/patch-src_mongo_db_kill_current_op.cpp	Fri May 16 07:58:04 2014	(r354198)
@@ -0,0 +1,11 @@
+--- src/mongo/db/kill_current_op.cpp.orig	2014-05-15 15:30:33.100157820 +0000
++++ src/mongo/db/kill_current_op.cpp	2014-05-15 15:35:12.714138934 +0000
+@@ -152,7 +152,7 @@
+         }
+ 
+         // Return true with (approx) probability p = "chance".  Recall: 0 <= chance <= 1.
+-        double next = static_cast<double>(std::abs(checkForInterruptPRNG.nextInt64()));
++        double next = std::abs(static_cast<double>(checkForInterruptPRNG.nextInt64()));
+         double upperBound =
+             std::numeric_limits<int64_t>::max() * failPointInfo["chance"].numberDouble();
+         if (next > upperBound) {

Added: head/databases/mongodb/files/patch-src_mongo_db_ops_modifier_push.cpp
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/databases/mongodb/files/patch-src_mongo_db_ops_modifier_push.cpp	Fri May 16 07:58:04 2014	(r354198)
@@ -0,0 +1,11 @@
+--- src/mongo/db/ops/modifier_push.cpp.orig	2014-05-15 15:24:21.650184430 +0000
++++ src/mongo/db/ops/modifier_push.cpp	2014-05-15 15:25:51.014179801 +0000
+@@ -646,7 +646,7 @@
+             }
+ 
+             const int64_t numChildren = mutablebson::countChildren(_preparedState->elemFound);
+-            int64_t countRemoved = std::max(static_cast<int64_t>(0), numChildren - abs(_slice));
++            int64_t countRemoved = std::max(static_cast<int64_t>(0), numChildren - (_slice >= 0 ? _slice : -_slice));
+ 
+             // If _slice is negative, remove from the bottom, otherwise from the top
+             const bool removeFromEnd = (_slice > 0);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201405160758.s4G7w4aT094466>