--- a/lib/getline.h +++ b/lib/getline.h @@ -27,6 +27,7 @@ # endif # endif +# if defined (__GLIBC__) # if __GLIBC__ < 2 int getline PARAMS ((char **_lineptr, size_t *_n, FILE *_stream)); @@ -34,5 +35,6 @@ int getdelim PARAMS ((char **_lineptr, size_t *_n, int _delimiter, FILE *_stream)); # endif +# endif #endif /* not GETLINE_H_ */ --- a/lib/realloc.c +++ b/lib/realloc.c @@ -20,21 +20,15 @@ #if HAVE_CONFIG_H # include #endif -#undef realloc -#include - -char *malloc (); -char *realloc (); +#include /* Change the size of an allocated block of memory P to N bytes, with error checking. If N is zero, change it to 1. If P is NULL, use malloc. */ char * -rpl_realloc (p, n) - char *p; - size_t n; +rpl_realloc (char *p, size_t n) { if (n == 0) n = 1; --- a/lib/xmalloc.c +++ b/lib/xmalloc.c @@ -20,15 +20,7 @@ #endif #include - -#if STDC_HEADERS -# include -#else -void *calloc (); -void *malloc (); -void *realloc (); -void free (); -#endif +#include #if ENABLE_NLS # include