]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
kraken: librbd: possible race in ExclusiveLock handle_peer_notification 14163/head
authorMykola Golub <mgolub@mirantis.com>
Tue, 28 Mar 2017 13:55:11 +0000 (15:55 +0200)
committerMykola Golub <mgolub@mirantis.com>
Tue, 28 Mar 2017 13:55:11 +0000 (15:55 +0200)
This is a direct commit to kraken -- the master diverged after
ManagedLock refactoring and is not affected.

Fix: http://tracker.ceph.com/issues/19368
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
src/librbd/ExclusiveLock.cc

index b8d740a94908908b0b67bd3e1dda6e08e8641b98..a268f20b87f27793c4fc9d8d8c6947dfce80108e 100644 (file)
@@ -242,6 +242,7 @@ void ExclusiveLock<I>::handle_peer_notification(int r) {
 
     ldout(m_image_ctx.cct, 10) << this << " " << __func__ << dendl;
     assert(get_active_action() == ACTION_REQUEST_LOCK);
+    m_state = STATE_ACQUIRING;
 
     if (r >= 0) {
       execute_next_action();