summaryrefslogtreecommitdiffstats
path: root/modules/mappers/mod_userdir.c
diff options
context:
space:
mode:
authorJeff Trawick <trawick@apache.org>2000-11-11 00:52:18 +0100
committerJeff Trawick <trawick@apache.org>2000-11-11 00:52:18 +0100
commitb8e4c889b3139308b9dc3c0688e6a8ee7f098306 (patch)
tree1ca0670e039512354da626e98e6ded78e7a65990 /modules/mappers/mod_userdir.c
parentMM has a bug that when you ask for a specific amount of shared memory (diff)
downloadapache2-b8e4c889b3139308b9dc3c0688e6a8ee7f098306.tar.xz
apache2-b8e4c889b3139308b9dc3c0688e6a8ee7f098306.zip
Get mod_userdir compiling on FreeBSD when APR_HAS_THREADS.
This doesn't account for the fact that getpwnam() isn't thread-safe on FreeBSD; it also doesn't account for systems where getpwnam_r lives outside of libc. See thread with subject "[?PATCH?] using getpwnam_r in mod_userdir" in Nov. 2000 new-httpd for some better long-term ideas for how to handle the problem. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@86917 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'modules/mappers/mod_userdir.c')
-rw-r--r--modules/mappers/mod_userdir.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/mappers/mod_userdir.c b/modules/mappers/mod_userdir.c
index b04d2a5556..56c236d54f 100644
--- a/modules/mappers/mod_userdir.c
+++ b/modules/mappers/mod_userdir.c
@@ -326,7 +326,7 @@ static int translate_userdir(request_rec *r)
#else /* WIN32 */
struct passwd *pw;
-#if APR_HAS_THREADS && defined(_POSIX_THREAD_SAFE_FUNCTIONS)
+#if APR_HAS_THREADS && defined(HAVE_GETPWNAM_R)
struct passwd pwd;
size_t buflen = sysconf(_SC_GETPW_R_SIZE_MAX);
char *buf = apr_pcalloc(r->pool, buflen);