]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
librbd: missing lock on state transition 7274/head
authorJason Dillaman <dillaman@redhat.com>
Mon, 18 Jan 2016 22:53:00 +0000 (17:53 -0500)
committerJason Dillaman <dillaman@redhat.com>
Mon, 18 Jan 2016 22:53:00 +0000 (17:53 -0500)
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
src/librbd/ExclusiveLock.cc

index fd362ef4a98c7837635fec7af8a82eed07819fba..cef72cceca797de89ae21ff1827aebb292fc1ca6 100644 (file)
@@ -339,8 +339,8 @@ void ExclusiveLock<I>::send_acquire_lock() {
 
 template <typename I>
 void ExclusiveLock<I>::handle_acquiring_lock(int r) {
-  CephContext *cct = m_image_ctx.cct;
-  ldout(cct, 10) << this << " " << __func__ << dendl;
+  Mutex::Locker locker(m_lock);
+  ldout(m_image_ctx.cct, 10) << this << " " << __func__ << dendl;
 
   assert(r == 0);
   assert(m_state == STATE_ACQUIRING);