This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
Re: Problem with per thread rpc context
- To: "H . J . Lu" <hjl at lucon dot org>
- Subject: Re: Problem with per thread rpc context
- From: Kaz Kylheku <kaz at ashi dot footprints dot net>
- Date: Mon, 30 Jul 2001 19:53:42 -0700 (PDT)
- cc: GNU C Library <libc-alpha at sourceware dot cygnus dot com>
On Mon, 30 Jul 2001, H . J . Lu wrote:
> Date: Mon, 30 Jul 2001 18:21:33 -0700
> From: H . J . Lu <hjl@lucon.org>
> To: GNU C Library <libc-alpha@sourceware.cygnus.com>
> Subject: Problem with per thread rpc context
>
> Glibc 2.2.4 has the per thread rpc context for thread safe rpc. It
> works if you don't want to share the rpc context. But in some cases,
> you do want to share the rpc context among different threads, like
> creating a rpc context in one thread, passing it around among threads
> and finally destroying it in a different thread.
Would it be possible to add some functions to allow a thread to install or
remove a context? Then a thread would still have its own *binding*
to a context, but the flexibility would be there to unbind the context
object and use it in another thread. A function would be able set up a
temporary context and then restore the old one before returning,
making contexts appear to be dynamically scoped.