]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
librbd: abort an image removal if block objects cannot be removed
authorJason Dillaman <dillaman@redhat.com>
Mon, 22 Jul 2019 13:48:26 +0000 (09:48 -0400)
committerJason Dillaman <dillaman@redhat.com>
Wed, 24 Jul 2019 13:31:30 +0000 (09:31 -0400)
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
src/librbd/image/RemoveRequest.cc

index d5154b977ee58c005b18743cbd9fabfba99b36c7..865df16d74e64a2f58f434a0436d624bf86c2225 100644 (file)
@@ -152,8 +152,10 @@ void RemoveRequest<I>::handle_trim_image(int r) {
   ldout(m_cct, 20) << "r=" << r << dendl;
 
   if (r < 0) {
-    lderr(m_cct) << "warning: failed to remove some object(s): "
+    lderr(m_cct) << "failed to remove some object(s): "
                  << cpp_strerror(r) << dendl;
+    send_close_image(r);
+    return;
   }
 
   if (m_old_format) {