28 |
#include "cap-intern.h" |
#include "cap-intern.h" |
29 |
|
|
30 |
|
|
31 |
static struct hurd_ihash server_to_sconn = HURD_IHASH_INITIALIZER; |
static struct hurd_ihash server_to_sconn |
32 |
|
= HURD_IHASH_INITIALIZER (HURD_IHASH_NO_LOCP); |
33 |
static pthread_mutex_t server_to_sconn_lock = PTHREAD_MUTEX_INITIALIZER; |
static pthread_mutex_t server_to_sconn_lock = PTHREAD_MUTEX_INITIALIZER; |
34 |
|
|
35 |
|
|
132 |
sconn->refs = 0; |
sconn->refs = 0; |
133 |
|
|
134 |
/* Enter the new server connection object. */ |
/* Enter the new server connection object. */ |
135 |
err = hurd_ihash_add (&server_to_sconn, server_thread, sconn, NULL); |
err = hurd_ihash_add (&server_to_sconn, server_thread, sconn); |
136 |
if (err) |
if (err) |
137 |
{ |
{ |
138 |
pthread_mutex_destroy (&sconn->lock); |
pthread_mutex_destroy (&sconn->lock); |
163 |
cap->scid = scid; |
cap->scid = scid; |
164 |
cap->dead_cb = NULL; |
cap->dead_cb = NULL; |
165 |
|
|
166 |
err = hurd_ihash_add (&sconn->id_to_cap, scid, cap, 0); |
err = hurd_ihash_add (&sconn->id_to_cap, scid, cap); |
167 |
if (err) |
if (err) |
168 |
{ |
{ |
169 |
_hurd_cap_sconn_dealloc (sconn); |
_hurd_cap_sconn_dealloc (sconn); |