Re: ORBit2 source clarification, please?
- From: Michael Meeks <michael ximian com>
- To: Diego Sevilla Ruiz <dsevilla ditec um es>
- Cc: orbit <orbit-list gnome org>,ERDI Gergo <cactus cactus rulez org>
- Subject: Re: ORBit2 source clarification, please?
- Date: 13 May 2002 10:24:53 +0100
Hi Diego,
On Fri, 2002-05-10 at 02:45, Diego Sevilla Ruiz wrote:
> I've been playing around with ORBit2-cpp (orbit-cpp-cactus
> branch) and I encountered some weird error when the client code of a C++
> CORBA program calls orb->shutdown. I have seen that in the corba-orb.c
> file, the following test is applied:
>
> if (((ORBit_RootObject)orb)->refs != 2 + leaked_adaptors) {
>
> (line 1116 of current HEAD), so my question is what does this "2" means?
>
> As a fact, all the C++ programs come to this line with a "refs"
> value of "1", which causes the following message to be printed:
Fascinating; the 2 is a magic number indeed - I think it's probably the
combination of the CORBA_ORB reference [ on itself ] and perhaps thee
RootPOA reference, or something else that's still left around at that
stage. Essentially if you wrap CORBA_ORB_init / shutdown you shouldn't
change the way the referencing works - I believe.
> ** (process:22791): WARNING **: CORBA_ORB_destroy: ORB still has 0 refs.
>
> So, is there any known patter (bad pattern, of course) which
> leads to this situation? If I had a better idea of what could be the
> cause, I could fix the c++ branch in this regard.
Um; no it's a bit of a mystery; start with an extremely simple program
that just inits the orb and shuts down, and see what's up. Alternatively
get that exit method to always dump the live references [ export
ORBIT2_DEBUG=refs AFAIR ], and see which 2 we normally leave and find
why with C++ we don't have them around.
Oh, and a comment there would be great to explain the 2.
Regards,
Michael.
--
mmeeks@gnu.org <><, Pseudo Engineer, itinerant idiot
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]