Lock the socket mutex when the xml parser is reset due to stream restart.

git-svn-id: http://yate.null.ro/svn/yate/trunk@3128 acf43c95-373e-0410-b603-e72c3f656dc1
This commit is contained in:
marian 2010-03-17 14:48:40 +00:00
parent c34ac0af90
commit d2010e3a13
1 changed files with 5 additions and 2 deletions

View File

@ -1328,8 +1328,11 @@ void JBStream::changeState(State newState, u_int64_t time)
DDebug(this,DebugAll,"Set timeouts start=" FMT64 " setup=" FMT64 " [%p]",
m_startTimeout,m_setupTimeout,this);
if (m_xmlDom) {
m_xmlDom->reset();
DDebug(this,DebugAll,"XML parser reset [%p]",this);
Lock lck(m_socketMutex);
if (m_xmlDom) {
m_xmlDom->reset();
DDebug(this,DebugAll,"XML parser reset [%p]",this);
}
}
break;
case Idle: