* sync.h (muto::initforce): Force initialization even when name != NULL.
* grp.cc (pwdgrp::pwdgrp): Use initforce since the enclosing structure is !NO_COPY.
This commit is contained in:
parent
322c131f9f
commit
f45c299dbe
@ -1,3 +1,10 @@
|
|||||||
|
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
|
||||||
|
is !NO_COPY.
|
||||||
|
|
||||||
2005-04-05 Christopher Faylor <cgf@timesys.com>
|
2005-04-05 Christopher Faylor <cgf@timesys.com>
|
||||||
|
|
||||||
* sync.h (muto::operator int): New operator.
|
* sync.h (muto::operator int): New operator.
|
||||||
|
@ -111,7 +111,7 @@ pwdgrp::pwdgrp (passwd *&pbuf) :
|
|||||||
{
|
{
|
||||||
read = &pwdgrp::read_passwd;
|
read = &pwdgrp::read_passwd;
|
||||||
parse = &pwdgrp::parse_passwd;
|
parse = &pwdgrp::parse_passwd;
|
||||||
pglock.init ("pwd_lock");
|
pglock.initforce ("pwd_lock");
|
||||||
}
|
}
|
||||||
|
|
||||||
pwdgrp::pwdgrp (__group32 *&gbuf) :
|
pwdgrp::pwdgrp (__group32 *&gbuf) :
|
||||||
@ -119,7 +119,7 @@ pwdgrp::pwdgrp (__group32 *&gbuf) :
|
|||||||
{
|
{
|
||||||
read = &pwdgrp::read_group;
|
read = &pwdgrp::read_group;
|
||||||
parse = &pwdgrp::parse_group;
|
parse = &pwdgrp::parse_group;
|
||||||
pglock.init ("grp_lock");
|
pglock.initforce ("grp_lock");
|
||||||
}
|
}
|
||||||
|
|
||||||
struct __group32 *
|
struct __group32 *
|
||||||
|
@ -28,6 +28,7 @@ public:
|
|||||||
void *tls; /* Tls of lock owner. */
|
void *tls; /* Tls of lock owner. */
|
||||||
// class muto *next;
|
// class muto *next;
|
||||||
|
|
||||||
|
muto *initforce (const char *s) {name = NULL; return init (s);}
|
||||||
/* The real constructor. */
|
/* The real constructor. */
|
||||||
muto *init (const char *) __attribute__ ((regparm (2)));
|
muto *init (const char *) __attribute__ ((regparm (2)));
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user