[omniORB] Thread-safety of Any with local calls

Chris Newbold cnewbold@laurelnetworks.com
Thu Oct 3 23:21:01 2002


On Mon, 2002-09-30 at 09:37, Duncan Grisby wrote:

> All is not lost, however. If you use the omniORB specific Any
> constructor that takes a void* argument, you can copy an Any without
> copying its underlying buffer. Use code like
> 
>   CORBA::Any* a = // something in concurrent use
>   CORBA::Any safe(a->type(), a->value())

Perhaps I read more into this statement than was intended, but it looks
like while the constructor which takes a void* is thread-safe, the call
to value() is not.

Other than not understanding that at first, I guess it doesn't make much
difference performance-wise.

-- 
====( Chris Newbold  <cnewbold@laurelnetworks.com> )==========================
      Laurel Networks, Inc. voice: +1 412 809 4200 fax: +1 412 809 4201
"If you fool around with a thing for very long you will screw it up." --Murphy
------------------------------------------------------------------------------