From 05446e8dd9d9494cf692006f441df61c46291bb5 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Andr=C3=A9=20Malo?= Date: Sat, 22 Feb 2003 15:25:44 +0000 Subject: [PATCH] Fix suexec compile error under SUNOS4, where strerror() doesn't exist. PR: 5913, 9977 Submitted by: Jonathan W Miner git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/1.3.x@98756 13f79535-47bb-0310-9956-ffa450edef68 --- src/CHANGES | 4 ++++ src/support/suexec.c | 5 +++++ 2 files changed, 9 insertions(+) diff --git a/src/CHANGES b/src/CHANGES index 706783308b9..6f11ce6d2f4 100644 --- a/src/CHANGES +++ b/src/CHANGES @@ -1,5 +1,9 @@ Changes with Apache 1.3.28 + *) Fix suexec compile error under SUNOS4, where strerror() doesn't + exist. PR 5913, 9977. + [Jonathan W Miner ] + *) Unix build: Add support for environment variable EXTRA_LDFLAGS_SHLIB, which allows the user to add to the hard-coded ld flags specified for DSOs. Compare with the existing LDFLAGS_SHLIB diff --git a/src/support/suexec.c b/src/support/suexec.c index 07bcb5cc7ff..39196a72089 100644 --- a/src/support/suexec.c +++ b/src/support/suexec.c @@ -111,6 +111,11 @@ int initgroups(const char *name, gid_t basegid) } #endif +#if defined(NEED_STRERROR) +extern char *sys_errlist[]; +#define strerror(x) sys_errlist[(x)] +#endif + #if defined(PATH_MAX) #define AP_MAXPATH PATH_MAX #elif defined(MAXPATHLEN) -- 2.47.2