From 473bf59297a9c8010fb35f505c872024ae3d259d Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 15 Oct 2009 10:26:27 +0000 Subject: correction bug threaded IvyApplication correction checkconnected self --- Ivy/IvyApplication.cxx | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'Ivy/IvyApplication.cxx') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 4b41bbe..ab0cd9e 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -50,6 +50,7 @@ IvyApplication::IvyApplication(Ivy * bus) appname = "Unknown"; AppConnectedCallbackCalled = false; readyToSend = 0; + regexp_in.clear(); InitializeCriticalSection(&m_SendReadySection ); } @@ -128,7 +129,6 @@ void IvyApplication::OnReceive(char * line) { TRACE("Quitting bad format %s\n", line); SendMsg(Error, Error, "bad format request expected 'type id ...'"); -// bus->RemoveApplication( this ); Close(); return; } @@ -141,9 +141,7 @@ void IvyApplication::OnReceive(char * line) TRACE("Quitting %s\n", line); #endif //IVY_DEBUG -// bus->RemoveApplication( this ); OnClose(0); - //Close(); break; case Error: @@ -185,7 +183,6 @@ void IvyApplication::OnReceive(char * line) regexp_str_in.resize( id + 1 ); }*/ regexp_in[ id ] = exp; - regexp_str_in[ id ] = arg; #ifdef IVY_DEBUG TRACE("Adding regexp[%d]='%s' size: %d\n",id,arg,regexp_in.size()); #endif //IVY_DEBUG @@ -199,8 +196,7 @@ void IvyApplication::OnReceive(char * line) if ( regexp_in[id] ) { exp = regexp_in[ id ]; - bus->CallBindingRemoveCallback( this, id, regexp_str_in[id].c_str() ); - + bus->CallBindingRemoveCallback( this, id, exp->getExpression() ); delete exp; regexp_in[ id ] = NULL; } @@ -234,7 +230,6 @@ void IvyApplication::OnReceive(char * line) TRACE("Quitting already connected %s\n", appname.c_str()); target->SendMsg( Error, Error, "already connected" ); - // bus->RemoveApplication( target ); target->Close(); } } @@ -348,7 +343,6 @@ void IvyApplication::OnClose(int nErrorCode) delete iter->second; regexp_in.clear(); Close(); - //bus->RemoveApplication( this ); } int IvyApplication::SendMsg(const char *message) -- cgit v1.1