From: Howard Chu Date: Wed, 16 Sep 2020 14:08:52 +0000 (+0100) Subject: ITS#9348 don't declare sys_errlist if not present X-Git-Tag: OPENLDAP_REL_ENG_2_5_0ALPHA~9^2~10 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=997b28d07ba5968de06a251f5c4c219e52dfaa26;p=thirdparty%2Fopenldap.git ITS#9348 don't declare sys_errlist if not present If HAVE_SYS_ERRLIST is false, nothing uses them anyway, so the declarations serve no purpose. Just breaks the compile if the library actually defines them (and we are avoiding using them). --- diff --git a/include/ac/errno.h b/include/ac/errno.h index 9e71f29dd8..b34ec76841 100644 --- a/include/ac/errno.h +++ b/include/ac/errno.h @@ -23,11 +23,7 @@ # include #endif -#ifndef HAVE_SYS_ERRLIST - /* no sys_errlist */ -# define sys_nerr 0 -# define sys_errlist ((char **)0) -#elif defined( DECL_SYS_ERRLIST ) +#if defined( HAVE_SYS_ERRLIST ) && defined( DECL_SYS_ERRLIST ) /* have sys_errlist but need declaration */ LDAP_LIBC_V(int) sys_nerr; LDAP_LIBC_V(char) *sys_errlist[];