diff options
author | Jeremy Allison <jra@samba.org> | 2007-10-18 17:40:25 -0700 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2007-10-18 17:40:25 -0700 |
commit | 30191d1a5704ad2b158386b511558972d539ce47 (patch) | |
tree | 4f46e5c4f28f672ab661aa18f45745860970a88c /source3/lib/util_sec.c | |
parent | 789856f63ff73fec66298e95c91c60db7bdaf14e (diff) | |
download | samba-30191d1a5704ad2b158386b511558972d539ce47.tar.gz samba-30191d1a5704ad2b158386b511558972d539ce47.tar.bz2 samba-30191d1a5704ad2b158386b511558972d539ce47.zip |
RIP BOOL. Convert BOOL -> bool. I found a few interesting
bugs in various places whilst doing this (places that assumed
BOOL == int). I also need to fix the Samba4 pidl generation
(next checkin).
Jeremy.
(This used to be commit f35a266b3cbb3e5fa6a86be60f34fe340a3ca71f)
Diffstat (limited to 'source3/lib/util_sec.c')
-rw-r--r-- | source3/lib/util_sec.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/source3/lib/util_sec.c b/source3/lib/util_sec.c index 7723d294fa..d7984ac999 100644 --- a/source3/lib/util_sec.c +++ b/source3/lib/util_sec.c @@ -39,7 +39,7 @@ #define DEBUG(x, y) printf y #define smb_panic(x) exit(1) -#define BOOL int +#define bool int #endif /* are we running as non-root? This is used by the regresison test code, @@ -82,7 +82,7 @@ gid_t sec_initial_gid(void) /**************************************************************************** are we running in non-root mode? ****************************************************************************/ -BOOL non_root_mode(void) +bool non_root_mode(void) { return (initial_uid != (uid_t)0); } @@ -476,7 +476,7 @@ main() /**************************************************************************** Check if we are setuid root. Used in libsmb and smbpasswd paranoia checks. ****************************************************************************/ -BOOL is_setuid_root(void) +bool is_setuid_root(void) { return (geteuid() == (uid_t)0) && (getuid() != (uid_t)0); } |