diff options
author | Samuel Just <sam.just@inktank.com> | 2013-02-25 21:36:29 +0100 |
---|---|---|
committer | Sage Weil <sage@inktank.com> | 2013-03-04 22:53:59 +0100 |
commit | 9e4722595cf749f4735db92dd0d7a3039b4a24db (patch) | |
tree | b37a3a8706d3a2c1426bdfd4f3e8af09eea611ad | |
parent | ReplicatedPG::C_OSD_CommittedPushedObject take epoch submitted (diff) | |
download | ceph-9e4722595cf749f4735db92dd0d7a3039b4a24db.tar.xz ceph-9e4722595cf749f4735db92dd0d7a3039b4a24db.zip |
ReplicatedPG::C_OSD_CommittedPushedObject: use intrusive_ptr for pg
Signed-off-by: Samuel Just <sam.just@inktank.com>
(cherry picked from commit 04ee8f478bbd587a711d0668c471cfc5c1cab06c)
-rw-r--r-- | src/osd/ReplicatedPG.h | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/osd/ReplicatedPG.h b/src/osd/ReplicatedPG.h index 800477003dd..0277e7f4b38 100644 --- a/src/osd/ReplicatedPG.h +++ b/src/osd/ReplicatedPG.h @@ -883,18 +883,16 @@ protected: } }; struct C_OSD_CommittedPushedObject : public Context { - ReplicatedPG *pg; + boost::intrusive_ptr<ReplicatedPG> pg; OpRequestRef op; epoch_t epoch; eversion_t last_complete; C_OSD_CommittedPushedObject( ReplicatedPG *p, OpRequestRef o, epoch_t epoch, eversion_t lc) : pg(p), op(o), epoch(epoch), last_complete(lc) { - pg->get(); } void finish(int r) { pg->_committed_pushed_object(op, epoch, last_complete); - pg->put(); } }; struct C_OSD_CompletedPushedObjectReplica : public Context { |