[omniORB] Getting ObjectId when using default servant
Duncan Grisby
dgrisby@uk.research.att.com
Mon, 04 Dec 2000 16:31:10 +0000
On Monday 4 December, Stefan Seefeld wrote:
> In berlin, too, we use a couple of threads spawned by our own library. Yet
> we use 'thread ids' for every thread. We do it this way:
>
> inline unsigned long Thread::id()
> {
> unsigned long *_id = reinterpret_cast<unsigned long *>(pthread_getspecific(id_key));
[...]
That works for pthreads. Unfortunately, Windows has no equivalent to
pthread's setspecific/getspecific. It allows you to attach data to a
thread, but does not automatically delete it when the thread exits.
I'm afraid you'll have to wait for omniORB 4 for
PortableServer::Current.
Cheers,
Duncan.
--
-- Duncan Grisby \ Research Engineer --
-- AT&T Laboratories Cambridge --
-- http://www.uk.research.att.com/~dpg1 --