From: Jason Dillaman Date: Wed, 9 Mar 2016 18:55:29 +0000 (-0500) Subject: librbd: permit watch flush to return error code X-Git-Tag: v10.1.0~183^2~1 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=a8e82a38099d3d6ac4b92c9ccc1f3203fe8c6b8a;p=ceph.git librbd: permit watch flush to return error code Signed-off-by: Jason Dillaman --- diff --git a/src/librbd/image/CloseRequest.cc b/src/librbd/image/CloseRequest.cc index fa75e942620..55e25ab3764 100644 --- a/src/librbd/image/CloseRequest.cc +++ b/src/librbd/image/CloseRequest.cc @@ -244,9 +244,12 @@ void CloseRequest::send_flush_image_watcher() { template void CloseRequest::handle_flush_image_watcher(int r) { CephContext *cct = m_image_ctx->cct; - ldout(cct, 10) << this << " " << __func__ << dendl; + ldout(cct, 10) << this << " " << __func__ << ": r=" << r << dendl; - assert(r == 0); + if (r < 0) { + lderr(cct) << "error flushing image watcher: " << cpp_strerror(r) << dendl; + } + save_result(r); finish(); }