diff options
author | Ian Kent <ikent@redhat.com> | 2009-04-20 09:50:57 -0400 |
---|---|---|
committer | Steve Dickson <steved@redhat.com> | 2009-04-20 09:50:57 -0400 |
commit | 3897d3fd71f58df9dd5b3543e85d901c1eac6fd4 (patch) | |
tree | 181ba5be73efd1a89906912b8ee4cf2a0865cee8 /src/rpc_soc.c | |
parent | ad150b37206b3376416d49e36ebda116456f226c (diff) | |
download | ti-rpc-3897d3fd71f58df9dd5b3543e85d901c1eac6fd4.tar.gz |
libtirpc-0.1.10 - tsd destory at unload
If tsd keys are created that use a function local to the library and
are not destroyed at library unload this can lead to a SEGV if the
library is unloaded before the last thread is unloaded.
Also, calling free() on an address previously belonging to the now
unloaded library might not be very good either. I'm not to clear
about what happens to data areas used by shared libraries in terms
of their presence or otherwise in the lifcycle of a shared library.
This patch assumes that all threads using the library have exited
prior to the library being unloaded but may be worth more thought.
Signed-off-by: Ian Kent <ikent@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
Diffstat (limited to 'src/rpc_soc.c')
-rw-r--r-- | src/rpc_soc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/rpc_soc.c b/src/rpc_soc.c index 5bf44e0..4e8cc5b 100644 --- a/src/rpc_soc.c +++ b/src/rpc_soc.c @@ -430,7 +430,7 @@ registerrpc(prognum, versnum, procnum, progname, inproc, outproc) * All the following clnt_broadcast stuff is convulated; it supports * the earlier calling style of the callback function */ -static thread_key_t clnt_broadcast_key = -1; +extern thread_key_t clnt_broadcast_key; /* * Need to translate the netbuf address into sockaddr_in address. |