From ac3da510d7e25f3432e393dcce3d18d89ccbf3f3 Mon Sep 17 00:00:00 2001 From: paulc Date: Fri, 4 Mar 2011 14:29:12 +0000 Subject: [PATCH] Start the M2PA ACK timer before sending the SIGTRAN packet. Prevents a race condition from clearing the timer too early. git-svn-id: http://yate.null.ro/svn/yate/trunk@4155 acf43c95-373e-0410-b603-e72c3f656dc1 --- libs/ysig/sigtran.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/libs/ysig/sigtran.cpp b/libs/ysig/sigtran.cpp index b366222e..8f21bc3f 100644 --- a/libs/ysig/sigtran.cpp +++ b/libs/ysig/sigtran.cpp @@ -1360,9 +1360,9 @@ void SS7M2PA::retransData() head[3] = m_needToAck & 0xff ; if (m_confTimer.started()) m_confTimer.stop(); - transmitMSG(1,M2PA, 1, *msg,1); if (!m_ackTimer.started()) m_ackTimer.start(); + transmitMSG(1,M2PA, 1, *msg,1); } } @@ -1401,11 +1401,9 @@ bool SS7M2PA::transmitMSU(const SS7MSU& msu) m_ackList.append(new DataBlock(packet)); if (m_dumpMsg) dumpMsg(1,M2PA,1,packet,1,true); - bool ok = transmitMSG(1,M2PA,1,packet,1); - lock.drop(); if (!m_ackTimer.started()) m_ackTimer.start(); - return ok; + return transmitMSG(1,M2PA,1,packet,1); } void SS7M2PA::notifyLayer(SignallingInterface::Notification event)