4 * Copyright 1998-2000 The OpenLDAP Foundation, Redwood City, California, USA
7 * Redistribution and use in source and binary forms are permitted only
8 * as authorized by the OpenLDAP Public License. A copy of this
9 * license is available at http://www.OpenLDAP.org/license.html or
10 * in file LICENSE in the top-level directory of the distribution.
16 #if defined( HAVE_ERRNO_H )
18 #elif defined( HAVE_SYS_ERRNO_H )
19 # include <sys/errno.h>
22 #ifndef HAVE_SYS_ERRLIST
25 # define sys_errlist ((char **)0)
26 #elif DECL_SYS_ERRLIST
27 /* have sys_errlist but need declaration */
28 LIBC_F (int) sys_nerr;
29 LIBC_F (char) *sys_errlist[];
33 #define STRERROR(err) strerror(err)
35 #define STRERROR(err) \
36 ((err) > -1 && (err) < sys_nerr ? sys_errlist[(err)] : "unknown")
39 #endif /* _AC_ERRNO_H */