From: rahuel Date: Thu, 9 Feb 2006 15:45:17 +0000 (+0000) Subject: include of Python.h must be the last one and generally X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=ac86079bf1c2fa4d4bef5382c4f96f08f15c07ca;p=modules%2Fkernel.git include of Python.h must be the last one and generally some system includes must be added before as : #include #include #include #include CORBA::ORB_ptr orb instead of _var Memory corruption with a char [40] --- diff --git a/src/Container/SALOME_Container.cxx b/src/Container/SALOME_Container.cxx index a97bb39dc..83a0715be 100644 --- a/src/Container/SALOME_Container.cxx +++ b/src/Container/SALOME_Container.cxx @@ -31,8 +31,12 @@ #endif #include +#include #include #include +#include +#include +#include #ifndef WNT #include @@ -67,7 +71,7 @@ int main(int argc, char* argv[]) //CORBA::ORB_var orb = CORBA::ORB_init( argc , argv ) ; ORB_INIT &init = *SINGLETON_::Instance() ; ASSERT(SINGLETON_::IsAlreadyExisting()); - CORBA::ORB_var orb = init(0 , 0 ) ; + CORBA::ORB_ptr orb = init(0 , 0 ) ; // LocalTraceCollector *myThreadTrace = SALOMETraceCollector::instance(orb); INFOS_COMPILATION; @@ -106,9 +110,9 @@ int main(int argc, char* argv[]) // add new container to the kill list #ifndef WNT - char aCommand[40]; - sprintf(aCommand, "addToKillList.py %d SALOME_Container", getpid()); - system(aCommand); + ostrstream aCommand ; + aCommand << "addToKillList.py " << getpid() << " SALOME_Container" << ends ; + system(aCommand.str()); #endif Engines_Container_i * myContainer @@ -120,10 +124,9 @@ int main(int argc, char* argv[]) Utils_Timer timer; timer.Start(); timer.Stop(); - MESSAGE("SALOME_Registry_Server.cxx - orb->run()"); timer.ShowAbsolute(); #endif - + HandleServerSideSignals(orb); }