From 4c5ba18e8dd5ca29e559137a9244c21f0c4604f1 Mon Sep 17 00:00:00 2001 From: abd Date: Fri, 21 Apr 2006 12:45:44 +0000 Subject: [PATCH] Fixed BUG with omniORB refCount. see file comment --- src/GEOM_I/GEOM_IOperations_i.cc | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/GEOM_I/GEOM_IOperations_i.cc b/src/GEOM_I/GEOM_IOperations_i.cc index 8170be2f7..b0f652b2e 100644 --- a/src/GEOM_I/GEOM_IOperations_i.cc +++ b/src/GEOM_I/GEOM_IOperations_i.cc @@ -38,7 +38,16 @@ GEOM_IOperations_i::GEOM_IOperations_i(PortableServer::POA_ptr thePOA, GEOM::GEOM_Gen_ptr theEngine, ::GEOM_IOperations* theImpl) :SALOME::GenericObj_i( thePOA ), _impl(theImpl), _engine(theEngine) { - thePOA->activate_object(this); + // Win32 porting: the next line is dangerous - GEOM_IOperations_i is an intermediate + // base class, therefore is not completely constructed here -> + // passing it to activate_object() leads to unpredictable behavior + // resulted from memory corruption ( Rational Purify reports ABR errors ). + // Moreover, all GEOM_IxxxOperation_i servant classes are activated implicitly + // by GEOM_Gen_i::GetxxxOperations() methods. + // Therefore, this line is commented. + // In case if does not have ImplicitActivation policy, then + // activate_object() calls will be necessary in all GEOM_IxxxOperation_i constructors! + //thePOA->activate_object(this); } //============================================================================= -- 2.39.2