From b8e4c889b3139308b9dc3c0688e6a8ee7f098306 Mon Sep 17 00:00:00 2001 From: Jeff Trawick Date: Fri, 10 Nov 2000 23:52:18 +0000 Subject: 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 --- modules/mappers/mod_userdir.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'modules/mappers/mod_userdir.c') 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); -- cgit v1.2.3