From d371d8b5d4e51aa6cdc3a0814f337729798baa4c Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Mon, 16 May 2016 10:14:23 -0400 Subject: [PATCH] osd: add OpContext::get_features() For convenience. Signed-off-by: Sage Weil --- src/osd/ReplicatedPG.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/osd/ReplicatedPG.h b/src/osd/ReplicatedPG.h index d076720be73..6b6b85bcc15 100644 --- a/src/osd/ReplicatedPG.h +++ b/src/osd/ReplicatedPG.h @@ -674,6 +674,12 @@ public: delete i->second.second; } } + uint64_t get_features() { + if (op && op->get_req()) { + return op->get_req()->get_connection()->get_features(); + } + return -1ll; + } }; using OpContextUPtr = std::unique_ptr; friend struct OpContext; -- 2.47.3