[omniORB] feature or bug? - pointer to returned value is null

Duncan Grisby duncan@grisby.org
Wed Mar 26 18:41:02 2003


On Wednesday 26 March, Adrian Rosoga wrote:

> I would like to know in what circumstances the return
> value (the pointer to the returned structure) from a
> remote method is null. The returned value is a pointer
> to a structure containing variable length data. See
> the code at the end of the message.

That should never happen.

[...]
> I'm using omniORB4 on a Solaris machine (SunOs 5.8).
> Everything compiled with Forte. CORBA is quite
> intensively used, the machine is at his limits. It
> looks like the problem is more likely to occur if the
> machine is overloaded.

Variable length structs are allocated on the heap, so it's possible
that the allocation with new would fail and return zero, due to
running out of memory. However, if that happened, you would expect a
segfault when the unmarshalling code tried to fill in the members of
the struct.

Please run with -ORBtraceLevel 25. That might print out some
information that shows what's going wrong.

Cheers,

Duncan.

-- 
 -- Duncan Grisby         --
  -- duncan@grisby.org     --
   -- http://www.grisby.org --