]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
client: Ensure file_cache cap is released.
authorChristopher Hoffman <choffman@redhat.com>
Fri, 8 Nov 2024 14:00:43 +0000 (14:00 +0000)
committerChristopher Hoffman <choffman@redhat.com>
Wed, 5 Nov 2025 13:59:34 +0000 (13:59 +0000)
Fixes: https://tracker.ceph.com/issues/68798
Fixes: https://tracker.ceph.com/issues/68831
Signed-off-by: Christopher Hoffman <choffman@redhat.com>
src/client/Client.cc

index b594de7b6d539b84e83ab72aaf3f16f96eba75ac..c806e391b6fb813a544083b9b7eb30acab23009e 100644 (file)
@@ -11747,6 +11747,8 @@ int Client::_read_async(Fh *f, uint64_t off, uint64_t len, bufferlist *bl,
 
     client_lock.lock();
     put_cap_ref(in, CEPH_CAP_FILE_CACHE);
+  } else {
+    put_cap_ref(in, CEPH_CAP_FILE_CACHE);
   }
 
   if (r >= 0) {