[omniORB] Segfaults and Examples
Duncan Grisby
dgrisby@uk.research.att.com
Thu, 18 Oct 2001 17:45:38 +0100
On Thursday 18 October, Chris McClimans wrote:
> orb = CORBA.ORB_init()
> rootPOA = orb.resolve_initial_references("RootPOA")
> myPolicies = rootPOA.create_lifespan_policy(PortableServer.PERSISTENT)
> myPOA = rootPOA.create_POA("myPOA",rootPOA._get_the_POAManager(),myPolicies)
This line is wrong. create_POA() takes a list of policies, not a
single policy object. The call should be
myPOA = rootPOA.create_POA("myPOA",rootPOA._get_the_POAManager(),[myPolicies])
However, it's a bug that omniORBpy segfaults when you use the wrong
type. I've checked in a fix so it now properly throws BAD_PARAM.
Cheers,
Duncan.
--
-- Duncan Grisby \ Research Engineer --
-- AT&T Laboratories Cambridge --
-- http://www.uk.research.att.com/~dpg1 --