Re: Should youtown the ORB from CORBA::ORB_init?



ERDI Gergo <cactus cactus rulez org> wrote:
> So, the question is, which one should be the correct behaviour, according
> to the CORBA specs?

Assuming I'm reading the specs right:

Section 1.23 of the C++ mapping says that pseudo objects may be
implemented as normal CORBA objects, or as serverless objects. It also
says that serverless objects need not follow the same memory management
rules as normal objects.

Section 1.25 of the C mapping also says that pseudo objects may be
implemented as normal objects, but don't need to be.

So the answer is it's up to the ORBit people, and by extension, you.

I think it makes the most sense to have all interfaces follow the same
memory management rules. If that were the case, then the ORB_init()
caller would own the ORB reference, and your code would be correct.

> Unfortunately, I just can't find a webpage about CORBA/C++ that would
> answer questions like this, so I'm counting on you guys.

The OMG CORBA language mappings define things like ownership for those
languages that don't do automatic garbage collection.
-- 
Sam "Eddie" Couter  |  mailto:sam couter dropbear id au
Debian Developer    |  mailto:eddie debian org
                    |  jabber:sam teknohaus dyndns org
OpenPGP fingerprint:  A46B 9BB5 3148 7BEA 1F05  5BD5 8530 03AE DE89 C75C

Attachment: pgpe5YqQhivqX.pgp
Description: PGP signature



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