mirror of https://github.com/mongodb/mongo
SERVER-109531 Fix ineffecient call to reserve() (#40399)
GitOrigin-RevId: 83fbdcf6babed5bfe752efa8cfd8d59918c7ef60
This commit is contained in:
parent
3e67bf6972
commit
af3751371f
|
|
@ -317,8 +317,8 @@ DocumentSourceGraphLookUp::DocumentSourceGraphLookUp(
|
|||
|
||||
// We append an additional BSONObj to '_fromPipeline' as a placeholder for the $match
|
||||
// stage we'll eventually construct from the input document.
|
||||
_fromPipeline.reserve(resolvedNamespace.pipeline.size() + 1);
|
||||
_fromPipeline = resolvedNamespace.pipeline;
|
||||
_fromPipeline.reserve(_fromPipeline.size() + 1);
|
||||
_fromPipeline.push_back(BSON("$match" << BSONObj()));
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue