diff options
author | Billy Donahue <billy.donahue@mongodb.com> | 2019-04-30 15:46:10 -0400 |
---|---|---|
committer | Billy Donahue <billy.donahue@mongodb.com> | 2019-05-16 16:38:58 -0400 |
commit | 8c4f95e45b8cf32c61f73bc4e2dd3beaa97e190c (patch) | |
tree | 7031f6d306c4c6adfac00c47cd925b729c324d5f /src/mongo/db/service_context.cpp | |
parent | 39413ef58dd1f667728b67c86e1bf09146952242 (diff) | |
download | mongo-8c4f95e45b8cf32c61f73bc4e2dd3beaa97e190c.tar.gz |
SERVER-40811 reduce GlobalInitializerRegisterer constructors
Diffstat (limited to 'src/mongo/db/service_context.cpp')
-rw-r--r-- | src/mongo/db/service_context.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mongo/db/service_context.cpp b/src/mongo/db/service_context.cpp index e83d983ca50..c7ed9d53083 100644 --- a/src/mongo/db/service_context.cpp +++ b/src/mongo/db/service_context.cpp @@ -377,7 +377,6 @@ ServiceContext::ConstructorActionRegisterer::ConstructorActionRegisterer( if (!destructor) destructor = [](ServiceContext*) {}; _registerer.emplace(std::move(name), - std::move(prereqs), [this, constructor, destructor](InitializerContext* context) { _iter = registeredConstructorActions().emplace( registeredConstructorActions().end(), @@ -388,7 +387,8 @@ ServiceContext::ConstructorActionRegisterer::ConstructorActionRegisterer( [this](DeinitializerContext* context) { registeredConstructorActions().erase(_iter); return Status::OK(); - }); + }, + std::move(prereqs)); } ServiceContext::UniqueServiceContext ServiceContext::make() { |