summaryrefslogtreecommitdiff
path: root/src/mongo/client
diff options
context:
space:
mode:
authorMatthew Russotto <matthew.russotto@10gen.com>2020-03-27 14:50:35 -0400
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2020-03-27 19:19:44 +0000
commitb70908c4898c4b02d8c70df3f796fa3e8cfe5bdd (patch)
treed29354ae8cf4931f7956de2eabd5bd56219027fc /src/mongo/client
parentdc7724efa185a1b64f95fc84d0f7794dbc2fcdae (diff)
downloadmongo-b70908c4898c4b02d8c70df3f796fa3e8cfe5bdd.tar.gz
SERVER-46085 Fail initial sync attempt if sync source is in initial sync
Diffstat (limited to 'src/mongo/client')
-rw-r--r--src/mongo/client/dbclient_mockcursor.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mongo/client/dbclient_mockcursor.cpp b/src/mongo/client/dbclient_mockcursor.cpp
index d70fe3b3d06..40b505c7abe 100644
--- a/src/mongo/client/dbclient_mockcursor.cpp
+++ b/src/mongo/client/dbclient_mockcursor.cpp
@@ -74,7 +74,7 @@ void DBClientMockCursor::_fillNextBatch() {
int leftInBatch = _batchSize;
batch.objs.clear();
while (_iter.more() && (!_batchSize || leftInBatch--)) {
- batch.objs.emplace_back(_iter.next().Obj());
+ batch.objs.emplace_back(_iter.next().Obj().getOwned());
}
batch.pos = 0;
@@ -92,4 +92,4 @@ boost::optional<BSONObj> DBClientMockCursor::getPostBatchResumeToken() const {
return _postBatchResumeToken;
}
-} // namespace mongo \ No newline at end of file
+} // namespace mongo