]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
osd/ReplicatedPG: pass PGPool to ReplicatedPG ctor by ref
authorSamuel Just <sam.just@inktank.com>
Wed, 29 Aug 2012 23:35:01 +0000 (16:35 -0700)
committerSage Weil <sage@inktank.com>
Fri, 31 Aug 2012 20:11:36 +0000 (13:11 -0700)
CID 717057: Big parameter passed by value (PASS_BY_VALUE)At (1): Passing
parameter _pool of type PGPool (size 336 bytes) by value.

Signed-off-by: Samuel Just <sam.just@inktank.com>
src/osd/ReplicatedPG.cc
src/osd/ReplicatedPG.h

index 8dfbff545aebf0b11c51ee0dbf8b3a41134a154b..077a422d45beb8799aa0bafcef582a1af8868f1e 100644 (file)
@@ -582,7 +582,7 @@ void ReplicatedPG::calc_trim_to()
 }
 
 ReplicatedPG::ReplicatedPG(OSDService *o, OSDMapRef curmap,
-                          PGPool _pool, pg_t p, const hobject_t& oid,
+                          const PGPool &_pool, pg_t p, const hobject_t& oid,
                           const hobject_t& ioid) :
   PG(o, curmap, _pool, p, oid, ioid), temp_created(false),
   temp_coll(coll_t::make_temp_coll(p)), snap_trimmer_machine(this)
index a96f62df01e6e8c178cbd365d7578be76ba75e64..6d8a820de992e83d609824b6cb0270ee146b641a 100644 (file)
@@ -918,7 +918,7 @@ protected:
 
 public:
   ReplicatedPG(OSDService *o, OSDMapRef curmap,
-              PGPool _pool, pg_t p, const hobject_t& oid,
+              const PGPool &_pool, pg_t p, const hobject_t& oid,
               const hobject_t& ioid);
   ~ReplicatedPG() {}