From 2429556a51e8f60b0d9bdee71ef7b34b367f2f38 Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Tue, 26 Jun 2012 17:10:40 -0700 Subject: [PATCH] msgr: fix pipe replacement assert We may replace an existing pipe in the STANDBY state if the previous attempt failed during accept() (see previous patches). This might fix #1378. Signed-off-by: Sage Weil --- src/msg/SimpleMessenger.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/msg/SimpleMessenger.cc b/src/msg/SimpleMessenger.cc index e345bcb931715..9835c35d9e3e7 100644 --- a/src/msg/SimpleMessenger.cc +++ b/src/msg/SimpleMessenger.cc @@ -824,7 +824,8 @@ int SimpleMessenger::Pipe::accept() << " == " << connect.connect_seq << dendl; assert(existing->state == STATE_CONNECTING || - existing->state == STATE_OPEN); // this will win + existing->state == STATE_OPEN || + existing->state == STATE_STANDBY); reply.tag = CEPH_MSGR_TAG_WAIT; existing->pipe_lock.Unlock(); msgr->lock.Unlock(); -- 2.39.5