From 8656ee07efbd5d47cde561d4ead67174970f989b Mon Sep 17 00:00:00 2001 From: Christopher Faylor Date: Sat, 26 Feb 2000 01:11:54 +0000 Subject: * exceptions.cc (interruptible): Make a little more structured. (call_handler): Allow signals to be sent even if signalled thread is stopped. Change order of signal_arrived arming/waiting threads clearing to eliminate a race. (reset_signal_arrived): New helper function. * malloc.cc (malloc_init): Use mutos so that signal handler can keep track of who owns the lock. (__malloc_lock): Ditto. (__malloc_unlock): Ditto. * sync.h (new_muto): Actually use a muto for the "buffer". * Makefile.in: Fix a dependency. --- winsup/cygwin/sync.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'winsup/cygwin/sync.cc') diff --git a/winsup/cygwin/sync.cc b/winsup/cygwin/sync.cc index 744eb8dc7..aa3978fe0 100644 --- a/winsup/cygwin/sync.cc +++ b/winsup/cygwin/sync.cc @@ -20,11 +20,12 @@ details. */ #include #include #include "winsup.h" +#include "sync.h" -muto muto_start (0, 0); +muto NO_COPY muto_start; /* Constructor */ -muto::muto(int inh, const char *name) : sync (0), visits(0), waiters(-1), tid (0), next (0) +muto::muto(int inh, const char *name) : sync (0), visits(0), waiters(-1), tid (0), next (NULL) { /* Create event which is used in the fallback case when blocking is necessary */ if (!(bruteforce = CreateEvent (inh ? &sec_all_nih : &sec_none_nih, FALSE, FALSE, name))) -- cgit v1.2.3