osdc/Objecter: move LingerOp's ctor to .cc

so the linkage of fmt::fmt does not spill out to other compilation
units.

Signed-off-by: Kefu Chai <kchai@redhat.com>
This commit is contained in:
Kefu Chai 2021-07-24 00:09:58 +08:00
parent ade690b549
commit 0e0d320525
2 changed files with 8 additions and 5 deletions

View File

@ -4716,6 +4716,13 @@ void Objecter::handle_command_reply(MCommandReply *m)
m->put();
}
Objecter::LingerOp::LingerOp(Objecter *o, uint64_t linger_id)
: objecter(o),
linger_id(linger_id),
watch_lock(ceph::make_shared_mutex(
fmt::format("LingerOp::watch_lock #{}", linger_id)))
{}
void Objecter::submit_command(CommandOp *c, ceph_tid_t *ptid)
{
shunique_lock sul(rwlock, ceph::acquire_unique);

View File

@ -2310,11 +2310,7 @@ public:
watch_pending_async.pop_front();
}
explicit LingerOp(Objecter *o, uint64_t linger_id)
: objecter(o), linger_id(linger_id),
watch_lock(ceph::make_shared_mutex(
fmt::format("LingerOp::watch_lock #{}", linger_id))) {}
LingerOp(Objecter *o, uint64_t linger_id);
const LingerOp& operator=(const LingerOp& r) = delete;
LingerOp(const LingerOp& o) = delete;