summaryrefslogtreecommitdiff
path: root/src/mongo/db/dbhelpers.cpp
diff options
context:
space:
mode:
authorA. Jesse Jiryu Davis <jesse@mongodb.com>2019-06-14 16:42:10 -0400
committerA. Jesse Jiryu Davis <jesse@mongodb.com>2019-06-14 19:23:18 -0400
commit47b380f03e8898f4706ff01fa2be64dfb72e0dba (patch)
treefb3508758c9abd0e297afee43ac847bf5aebcbbb /src/mongo/db/dbhelpers.cpp
parentb3c26131f6ab3f919beca658341e737de5d45683 (diff)
downloadmongo-47b380f03e8898f4706ff01fa2be64dfb72e0dba.tar.gz
SERVER-41071 Replace NULL and 0 with nullptr
Diffstat (limited to 'src/mongo/db/dbhelpers.cpp')
-rw-r--r--src/mongo/db/dbhelpers.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mongo/db/dbhelpers.cpp b/src/mongo/db/dbhelpers.cpp
index 1447ad18389..e9bfdf9dff1 100644
--- a/src/mongo/db/dbhelpers.cpp
+++ b/src/mongo/db/dbhelpers.cpp
@@ -176,7 +176,7 @@ bool Helpers::getSingleton(OperationContext* opCtx, const char* ns, BSONObj& res
AutoGetCollectionForReadCommand ctx(opCtx, NamespaceString(ns));
auto exec =
InternalPlanner::collectionScan(opCtx, ns, ctx.getCollection(), PlanExecutor::NO_YIELD);
- PlanExecutor::ExecState state = exec->getNext(&result, NULL);
+ PlanExecutor::ExecState state = exec->getNext(&result, nullptr);
CurOp::get(opCtx)->done();
@@ -195,7 +195,7 @@ bool Helpers::getLast(OperationContext* opCtx, const char* ns, BSONObj& result)
AutoGetCollectionForReadCommand autoColl(opCtx, NamespaceString(ns));
auto exec = InternalPlanner::collectionScan(
opCtx, ns, autoColl.getCollection(), PlanExecutor::NO_YIELD, InternalPlanner::BACKWARD);
- PlanExecutor::ExecState state = exec->getNext(&result, NULL);
+ PlanExecutor::ExecState state = exec->getNext(&result, nullptr);
// Non-yielding collection scans from InternalPlanner will never error.
invariant(PlanExecutor::ADVANCED == state || PlanExecutor::IS_EOF == state);