doesn't work.  at all.

run cherokee as any user and get:
ERROR: Group '_cherokee' not found in the system

the group does exist.  the problem is the cherokee_getgrnam function calls 
getgrnam_r which returns 34, ERANGE.

i propose the following patch, which makes it work as expected.

--- cherokee/util.c.orig        Thu Jul 23 00:36:34 2009
+++ cherokee/util.c     Thu Jul 23 00:36:36 2009
@@ -1178,14 +1178,14 @@
 }
 
 
-#if defined(HAVE_PTHREAD) && !defined(HAVE_GETGRNAM_R)
+#if defined(HAVE_PTHREAD) && !defined(HAVE_GETGRNAM_RCRAP)
 static pthread_mutex_t __global_getgrnam_mutex = PTHREAD_MUTEX_INITIALIZER;
 #endif
 
 ret_t 
 cherokee_getgrnam (const char *name, struct group *grbuf, char *buf, size_t 
buflen)
 {
-#ifndef HAVE_GETGRNAM_R
+#ifndef HAVE_GETGRNAM_RCRAP
        size_t        gr_name_len   = 0;
        size_t        gr_passwd_len = 0;
        char         *ptr;

Reply via email to