Re: Memory management questions



Hi Olivier,

On Thu, 2003-09-04 at 18:05, Olivier Andrieu wrote:
>   - it's a bit silly since the orb already has this information and
>     could release the objects by himself it seems ;

	:-) sure; but the code is there to catch the user's mistakes so ...

> So, why does CORBA_ORB_destroy fail when there are still object
> references ? Is it simply to force programmers to properly release all
> their objects before exit or is there some other reason ?

	Well - it's a debugging option; this should only happen if you compile
ORBit2 with --enable-debug=yes, otherwise it'll set the exception but
just exit silently.

	So - most people will never see this I suppose; it's really there to
help C programmers who have problems remembering to type all those
ref/unref pairs.

	We can add API, or perhaps some argv tweak to turn this off if it's
really annoying you :-) do post a patch to
ORbit2/src/orb/orb-core/corba-orb.c adding some option like that.

	Regards,

		Michael.

-- 
 michael@ximian.com  <><, Pseudo Engineer, itinerant idiot




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]