From: Kurt Zeilenga Date: Sat, 24 Oct 1998 20:46:54 +0000 (+0000) Subject: We're assuming STDC all the way. X-Git-Tag: PHP3_TOOL_0_0~18^2~4 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=e671bb2e579e01c529d9ec962420b6f302821ed5;p=openldap We're assuming STDC all the way. --- diff --git a/include/ac/errno.h b/include/ac/errno.h index b4854c8ba0..b083cbbdf5 100644 --- a/include/ac/errno.h +++ b/include/ac/errno.h @@ -3,10 +3,10 @@ #ifndef _AC_ERRNO_H #define _AC_ERRNO_H -#if defined( HAVE_SYS_ERRNO_H ) -# include -#elif defined( HAVE_ERRNO_H ) +#if defined( HAVE_ERRNO_H ) # include +#elif defined( HAVE_SYS_ERRNO_H ) +# include #endif #ifdef DECL_SYS_ERRLIST diff --git a/include/ac/socket.h b/include/ac/socket.h index 3530b4896b..1527d02e5f 100644 --- a/include/ac/socket.h +++ b/include/ac/socket.h @@ -88,6 +88,7 @@ #define PDP_ENDIAN 3412 /* LSB first in word, MSW first in long */ /* assume autoconf's AC_C_BIGENDIAN has been run */ +/* if it hasn't, we assume (maybe falsely) the order is LITTLE ENDIAN */ #ifdef WORDS_BIGENDIAN #define BYTE_ORDER BIG_ENDIAN #else diff --git a/include/ac/string.h b/include/ac/string.h index cbe24c190f..2a923e9356 100644 --- a/include/ac/string.h +++ b/include/ac/string.h @@ -3,7 +3,7 @@ #ifndef _AC_STRING_H #define _AC_STRING_H -#if STDC_HEADERS +#ifdef STDC_HEADERS # include #else # ifndef HAVE_STRCHR @@ -18,18 +18,15 @@ # endif #endif -#ifdef HAVE_MEMMOVE -# define SAFEMEMCPY( d, s, n ) memmove((s), (d), (n)) +#if defined( HAVE_MEMMOVE ) +#define SAFEMEMCPY( d, s, n ) memmove((s), (d), (n)) +#elif defined( HAVE_BCOPY ) +#define SAFEMEMCPY( d, s, n ) bcopy((s), (d), (n)) +#elif defined( MACOS ) +#define SAFEMEMCPY( d, s, n ) BlockMoveData((Ptr)(s), (Ptr)(d), (n)) #else -# ifdef HAVE_BCOPY -# define SAFEMEMCPY( d, s, n ) bcopy((s), (d), (n)) -# else -# ifdef MACOS -# define SAFEMEMCPY( d, s, n ) BlockMoveData((Ptr)(s), (Ptr)(d), (n)) -# else -# define SAFEMEMCPY( d, s, n ) memmove((s), (d), (n)) -# endif -# endif +/* nothing left but memcpy() */ +#define SAFEMEMCPY( d, s, n ) memcpy((s), (d), (n)) #endif #endif /* _AC_STRING_H */ diff --git a/include/ac/time.h b/include/ac/time.h index 9cc89f43b4..ba18790a4c 100644 --- a/include/ac/time.h +++ b/include/ac/time.h @@ -6,12 +6,10 @@ #if TIME_WITH_SYS_TIME # include # include +#elif HAVE_SYS_TIME_H +# include #else -# if HAVE_SYS_TIME_H -# include -# else -# include -# endif +# include #endif #endif /* _AC_TIME_H */