1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-06-14 07:30:32 +02:00

Use Gnulib's inet_ntop' and inet_pton' modules.

* m4/gnulib-cache.m4: Add `inet_ntop' and `inet_pton'.

* configure.ac: Don't check for `inet_ntop' and `inet_pton'.

* libguile/socket.c (scm_inet_pton, scm_inet_ntop): Compile regardless
  of `HAVE_INET_PTON' and `HAVE_INET_NTOP' respectively.

* libguile/filesys.c: Use <stdlib.h> instead of <canonicalize.h>.
This commit is contained in:
Ludovic Courtès 2009-11-15 20:16:40 +01:00
parent 3fe87cf7af
commit 8912421cf3
60 changed files with 4550 additions and 1006 deletions

View file

@ -31,6 +31,7 @@
# else
# include "strftime.h"
# endif
# include "ignore-value.h"
#endif
#include <ctype.h>
@ -198,12 +199,25 @@ extern char *tzname[];
#if FPRINTFTIME
# define cpy(n, s) \
add ((n), \
do \
{ \
if (to_lowcase) \
fwrite_lowcase (p, (s), _n); \
else if (to_uppcase) \
fwrite_uppcase (p, (s), _n); \
else \
fwrite ((s), _n, 1, p))
{ \
/* We are ignoring the value of fwrite here, in spite of the \
fact that technically, that may not be valid: the fwrite \
specification in POSIX 2008 defers to that of fputc, which \
is intended to be consistent with the one from ISO C, \
which permits failure due to ENOMEM *without* setting the \
stream's error indicator. */ \
ignore_value (fwrite ((s), _n, 1, p)); \
} \
} \
while (0) \
)
#else
# define cpy(n, s) \
add ((n), \