From: Edward Hope-Morley Date: Thu, 11 Jul 2013 17:26:22 +0000 (+0100) Subject: Fixed Ceph backup librbd segfault X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=e830c8d3fa0abc64e5ff75dfd0729d053f26971a;p=openstack-build%2Fcinder-build.git Fixed Ceph backup librbd segfault Change-Id: I1a6b9935eb7da9fca5b572ea4823bae3def99ea0 Fixes: bug #1198271 --- diff --git a/cinder/volume/drivers/rbd.py b/cinder/volume/drivers/rbd.py index 533d58441..288742b08 100644 --- a/cinder/volume/drivers/rbd.py +++ b/cinder/volume/drivers/rbd.py @@ -159,6 +159,13 @@ class RBDImageIOWrapper(io.RawIOBase): """ raise IOError("fileno() not supported by RBD()") + # NOTE(dosaboy): if IO object is not closed explicitly, Python auto closes + # it which, if this is not overridden, calls flush() prior to close which + # in this case is unwanted since the rbd image may have been closed prior + # to the autoclean - currently triggering a segfault in librbd. + def close(self): + pass + class RBDVolumeProxy(object): """