corremn
2011-11-24 05:19:56 UTC
Hi,
Due to programming architecture I am in the need to init the ORB,
create a servant, incarnate the CORBA object (using _this), "do
stuff", destroy the object and call ORB->destroy.
I.e
orb = CORBA::ORB_init(...)
....
{
Test_impl vTestServant;
Test_var vObject = vTestServant._this();
}
.....
orb->destroy(); //so I can re-init the ORB in my app.
This code replicates my architecture problem. Note the '{' and '}' to
represent scoping. Here lies my problem. Once vTestServant goes out of
scope prior to orb->destroy been called, I then get a pure virtual
function call on orb->destroy(). (MSVC debug).
Is there a way to unregister servant with POA or something so this
does not happen? (something to reverse the effect of the _this()
call?) Note that this has nothing to do with activation/deactivation
of objects.
Cheers
Due to programming architecture I am in the need to init the ORB,
create a servant, incarnate the CORBA object (using _this), "do
stuff", destroy the object and call ORB->destroy.
I.e
orb = CORBA::ORB_init(...)
....
{
Test_impl vTestServant;
Test_var vObject = vTestServant._this();
}
.....
orb->destroy(); //so I can re-init the ORB in my app.
This code replicates my architecture problem. Note the '{' and '}' to
represent scoping. Here lies my problem. Once vTestServant goes out of
scope prior to orb->destroy been called, I then get a pure virtual
function call on orb->destroy(). (MSVC debug).
Is there a way to unregister servant with POA or something so this
does not happen? (something to reverse the effect of the _this()
call?) Note that this has nothing to do with activation/deactivation
of objects.
Cheers