* bsd_mutex.cc (_msleep): Release process object while waiting.
This commit is contained in:
parent
26657d6052
commit
1532dd53a5
@ -1,3 +1,7 @@
|
||||
2004-08-24 Corinna Vinschen <corinna@vinschen.de>
|
||||
|
||||
* bsd_mutex.cc (_msleep): Release process object while waiting.
|
||||
|
||||
2004-08-03 Corinna Vinschen <corinna@vinschen.de>
|
||||
|
||||
* transport.cc (transport_layer_base::~transport_layer_base): Resurrect.
|
||||
|
@ -201,6 +201,7 @@ _msleep (void *ident, struct mtx *mtx, int priority,
|
||||
if ((priority & PCATCH)
|
||||
&& td->client->signal_arrived () != INVALID_HANDLE_VALUE)
|
||||
obj_cnt = 4;
|
||||
td->client->release ();
|
||||
switch (WaitForMultipleObjects (obj_cnt, obj, FALSE, timo ?: INFINITE))
|
||||
{
|
||||
case WAIT_OBJECT_0: /* wakeup() has been called. */
|
||||
@ -225,6 +226,7 @@ _msleep (void *ident, struct mtx *mtx, int priority,
|
||||
/* Dismiss event before entering mutex. */
|
||||
ResetEvent (evt);
|
||||
CloseHandle (evt);
|
||||
td->client->hold ();
|
||||
set_priority (old_priority);
|
||||
if (mtx && !(priority & PDROP))
|
||||
mtx_lock (mtx);
|
||||
|
Loading…
x
Reference in New Issue
Block a user