]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
tools/immutable_object_cache: don't leak in-flight replies on teardown 70589/head
authorSun Yuechi <sunyuechi@iscas.ac.cn>
Sun, 21 Jun 2026 08:42:54 +0000 (16:42 +0800)
committerIlya Dryomov <idryomov@gmail.com>
Mon, 27 Jul 2026 17:57:42 +0000 (19:57 +0200)
commit413b4ff2235e962d49ddfb7f8381884c6b8d0dc6
tree7f78178f4eb990516068f52966adc2e1c7a1908d
parent2d5e0bb24629bd3f4c40c7ba98b9cce1bd12180a
tools/immutable_object_cache: don't leak in-flight replies on teardown

CacheSession::send() deleted the reply in the async_write completion
handler. On teardown asio drops the pending handler without running it,
leaking the reply. Delete it right after encoding into bl instead; bl
owns the payload, so the write is unaffected.

Fixes: https://tracker.ceph.com/issues/77552
Signed-off-by: Sun Yuechi <sunyuechi@iscas.ac.cn>
(cherry picked from commit 2d85d9e15855e662a4235c38c683a533213be934)
src/tools/immutable_object_cache/CacheSession.cc