From: Werner Koch Date: Thu, 10 Dec 2009 09:49:47 +0000 (+0000) Subject: Test on sgid process X-Git-Tag: gpgme-1.3.0~8 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=31844d30cd604d3da90a0f773f92c7468a9c5b22;p=gpgme.git Test on sgid process --- diff --git a/ChangeLog b/ChangeLog index 5ed2a8d..798f04b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2009-12-10 Werner Koch + + * configure.ac: Check for getgid and getegid. + 2009-12-08 Marcus Brinkmann Update to libtool 2.2.6a. diff --git a/configure.ac b/configure.ac index 9d4cf42..8578297 100644 --- a/configure.ac +++ b/configure.ac @@ -746,6 +746,10 @@ if test $ac_cv_func_funopen != yes; then fi fi +# Check for getgid etc +AC_CHECK_FUNCS(getgid getegid) + + # Replacement functions. AC_REPLACE_FUNCS(stpcpy) # Check for unistd.h for setenv replacement function. diff --git a/src/ChangeLog b/src/ChangeLog index 608db50..61bc394 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2009-12-10 Werner Koch + + * debug.c (debug_init): Test on sgid process. + 2009-12-08 Marcus Brinkmann * Makefile.am (LTRCCOMPILE): Refactor with ... @@ -5810,7 +5814,7 @@ * wait.c: Include `engine.h'. (run_idle): Call _gpgme_engine_housecleaning(), not _gpgme_gpg_housecleaning(). - + 2001-12-18 Marcus Brinkmann * key.c (_gpgme_key_append_name): Append, not prepend, the uid. diff --git a/src/debug.c b/src/debug.c index d3fce77..1471ff2 100644 --- a/src/debug.c +++ b/src/debug.c @@ -131,7 +131,11 @@ debug_init (void) if (s1) { #ifndef HAVE_DOSISH_SYSTEM - if (getuid () == geteuid ()) + if (getuid () == geteuid () +#if defined(HAVE_GETGID) && defined(HAVE_GETEGID) + && getgid () == getegid () +#endif + ) { #endif char *p;