aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2020-06-19 11:32:01 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2020-06-19 11:32:01 +0200
commit7017f97de25b82db06b6067d2716286be169cb71 (patch)
treed0e288149782a58548b7e4c976a8ff087f850558
parentcd3c920c2153c5e1397683860011df7856a1a0c0 (diff)
Get rid of unnecessary copies
-rw-r--r--bpkg/package.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/bpkg/package.cxx b/bpkg/package.cxx
index 7768665..8c3fd19 100644
--- a/bpkg/package.cxx
+++ b/bpkg/package.cxx
@@ -191,7 +191,7 @@ namespace bpkg
for (shared_ptr<available_package> ap: pointer_result (apr))
{
- for (const shared_ptr<repository_fragment> r: rps)
+ for (const shared_ptr<repository_fragment>& r: rps)
{
if (shared_ptr<repository_fragment> rf = filter (r, ap, prereq))
{
@@ -214,7 +214,7 @@ namespace bpkg
for (shared_ptr<available_package> ap: pointer_result (apr))
{
- for (const shared_ptr<repository_fragment> r: rps)
+ for (const shared_ptr<repository_fragment>& r: rps)
{
if (shared_ptr<repository_fragment> rf = filter (r, ap, prereq))
return result (move (ap), move (rf));