summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--winsup/cygwin/ChangeLog6
-rw-r--r--winsup/cygwin/grp.cc6
-rw-r--r--winsup/cygwin/pwdgrp.h2
-rw-r--r--winsup/cygwin/sigproc.cc2
-rw-r--r--winsup/cygwin/sync.h1
5 files changed, 12 insertions, 5 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog
index 212fe89a3..0e1a78eea 100644
--- a/winsup/cygwin/ChangeLog
+++ b/winsup/cygwin/ChangeLog
@@ -1,5 +1,11 @@
2005-04-05 Christopher Faylor <cgf@timesys.com>
+ * sync.h (muto::initforce): Delete flawed implementation.
+ * pwdgrp.h (pwdgrp::pglock): Make static.
+ * grp.cc (pwdgrp::pwdgrp): Eliminate use of initforce.
+
+2005-04-05 Christopher Faylor <cgf@timesys.com>
+
* sync.h (muto::initforce): Force initialization even when name !=
NULL.
* grp.cc (pwdgrp::pwdgrp): Use initforce since the enclosing structure
diff --git a/winsup/cygwin/grp.cc b/winsup/cygwin/grp.cc
index 190d9cb26..e79383999 100644
--- a/winsup/cygwin/grp.cc
+++ b/winsup/cygwin/grp.cc
@@ -106,12 +106,14 @@ pwdgrp::read_group ()
return;
}
+muto NO_COPY pwdgrp::pglock;
+
pwdgrp::pwdgrp (passwd *&pbuf) :
pwdgrp_buf_elem_size (sizeof (*pbuf)), passwd_buf (&pbuf)
{
read = &pwdgrp::read_passwd;
parse = &pwdgrp::parse_passwd;
- pglock.initforce ("pwd_lock");
+ pglock.init ("pglock");
}
pwdgrp::pwdgrp (__group32 *&gbuf) :
@@ -119,7 +121,7 @@ pwdgrp::pwdgrp (__group32 *&gbuf) :
{
read = &pwdgrp::read_group;
parse = &pwdgrp::parse_group;
- pglock.initforce ("grp_lock");
+ pglock.init ("pglock");
}
struct __group32 *
diff --git a/winsup/cygwin/pwdgrp.h b/winsup/cygwin/pwdgrp.h
index 53899e87d..94631c5e6 100644
--- a/winsup/cygwin/pwdgrp.h
+++ b/winsup/cygwin/pwdgrp.h
@@ -39,7 +39,7 @@ class pwdgrp
char *buf, *lptr;
int max_lines;
bool initialized;
- muto pglock;
+ static muto pglock;
bool parse_passwd ();
bool parse_group ();
diff --git a/winsup/cygwin/sigproc.cc b/winsup/cygwin/sigproc.cc
index 564a805b0..91b289447 100644
--- a/winsup/cygwin/sigproc.cc
+++ b/winsup/cygwin/sigproc.cc
@@ -70,7 +70,7 @@ Static char cprocs[(NPROCS + 1) * sizeof (pinfo)];// All my children info
// constructor operation at DLL startup
Static waitq waitq_head = {0, 0, 0, 0, 0, 0, 0};// Start of queue for wait'ing threads
-muto NO_COPY sync_proc_subproc; // Control access to subproc stuff
+static muto NO_COPY sync_proc_subproc; // Control access to subproc stuff
DWORD NO_COPY sigtid = 0; // ID of the signal thread
diff --git a/winsup/cygwin/sync.h b/winsup/cygwin/sync.h
index 13fa33caf..441892a08 100644
--- a/winsup/cygwin/sync.h
+++ b/winsup/cygwin/sync.h
@@ -28,7 +28,6 @@ public:
void *tls; /* Tls of lock owner. */
// class muto *next;
- muto *initforce (const char *s) {name = NULL; return init (s);}
/* The real constructor. */
muto *init (const char *) __attribute__ ((regparm (2)));