crimson/net: move from out_q into sent queue

to avoid the refcounting of underlying RefCountedObject.

Signed-off-by: Kefu Chai <kchai@redhat.com>
This commit is contained in:
Kefu Chai 2021-06-04 20:19:30 +08:00
parent 523fcb711f
commit 7d6c43d81c

View File

@ -103,8 +103,8 @@ ceph::bufferlist Protocol::sweep_messages_and_move_to_sent(
require_ack);
if (!conn.policy.lossy) {
conn.sent.insert(conn.sent.end(),
conn.out_q.begin(),
conn.out_q.end());
std::make_move_iterator(conn.out_q.begin()),
std::make_move_iterator(conn.out_q.end()));
}
conn.out_q.clear();
return bl;