mirror of
https://github.com/rkd77/elinks.git
synced 2024-12-04 14:46:47 -05:00
commit
26d1759d35
@ -198,7 +198,6 @@ AC_CHECK_HEADERS(sys/fmutex.h)
|
||||
AC_CHECK_HEADERS(sys/ioctl.h sys/sockio.h)
|
||||
AC_CHECK_HEADERS(sys/resource.h)
|
||||
AC_CHECK_HEADERS(sys/select.h)
|
||||
AC_CHECK_HEADERS(sys/signal.h)
|
||||
AC_CHECK_HEADERS(sys/socket.h)
|
||||
AC_CHECK_HEADERS(sys/time.h)
|
||||
AC_CHECK_HEADERS(sys/utsname.h)
|
||||
@ -323,13 +322,6 @@ if test x"$HAVE_RAISE" = x; then
|
||||
fi
|
||||
fi
|
||||
|
||||
AC_CACHE_CHECK([for __va_copy],el_cv_HAVE_VA_COPY,[
|
||||
AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <stdarg.h>
|
||||
va_list ap1,ap2;]], [[__va_copy(ap1,ap2);]])],[el_cv_HAVE_VA_COPY=yes],[el_cv_HAVE_VA_COPY=no])])
|
||||
if test x"$el_cv_HAVE_VA_COPY" = x"yes"; then
|
||||
EL_DEFINE(HAVE_VA_COPY, __va_copy)
|
||||
fi
|
||||
|
||||
AC_CACHE_CHECK([for sysconf(_SC_PAGE_SIZE)],el_cv_HAVE_SC_PAGE_SIZE,[
|
||||
AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <unistd.h>
|
||||
]], [[int page_size = sysconf(_SC_PAGE_SIZE);]])],[el_cv_HAVE_SC_PAGE_SIZE=yes],[el_cv_HAVE_SC_PAGE_SIZE=no])])
|
||||
|
@ -100,7 +100,7 @@ msg_text_do(unsigned char *format, va_list ap)
|
||||
int infolen, len;
|
||||
va_list ap2;
|
||||
|
||||
VA_COPY(ap2, ap);
|
||||
va_copy(ap2, ap);
|
||||
|
||||
infolen = vsnprintf(NULL, 0, format, ap2);
|
||||
info = mem_alloc(infolen + 1);
|
||||
|
@ -162,7 +162,7 @@ trigger_event_va(int id, va_list ap_init)
|
||||
enum evhook_status ret;
|
||||
va_list ap;
|
||||
|
||||
VA_COPY(ap, ap_init);
|
||||
va_copy(ap, ap_init);
|
||||
ret = ev_handler->callback(ap, ev_handler->data);
|
||||
va_end(ap);
|
||||
|
||||
|
@ -7,9 +7,6 @@
|
||||
#include <errno.h>
|
||||
#include <signal.h>
|
||||
#include <string.h> /* FreeBSD FD_ZERO() macro calls bzero() */
|
||||
#ifdef HAVE_SYS_SIGNAL_H
|
||||
#include <sys/signal.h>
|
||||
#endif
|
||||
#ifdef __GNU__ /* For GNU Hurd bug workaround in set_handlers() */
|
||||
#include <sys/stat.h> /* OS/2 needs this after sys/types.h */
|
||||
#endif
|
||||
|
@ -7,18 +7,10 @@
|
||||
#include <limits.h> /* may contain PIPE_BUF definition on some systems */
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_SYS_SIGNAL_H
|
||||
#include <sys/signal.h> /* may contain SA_RESTART */
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_STDDEF_H
|
||||
#include <stddef.h> /* may contain offsetof() */
|
||||
#endif
|
||||
|
||||
#ifndef SA_RESTART
|
||||
#define SA_RESTART 0
|
||||
#endif
|
||||
|
||||
#ifndef PIPE_BUF
|
||||
#define PIPE_BUF 512 /* POSIX says that. -- Mikulas */
|
||||
#endif
|
||||
|
@ -15,9 +15,6 @@
|
||||
#ifdef HAVE_SYS_IOCTL_H
|
||||
#include <sys/ioctl.h>
|
||||
#endif
|
||||
#ifdef HAVE_SYS_SIGNAL_H
|
||||
#include <sys/signal.h>
|
||||
#endif
|
||||
#include <sys/types.h>
|
||||
#ifdef HAVE_SYS_SOCKET_H
|
||||
#include <sys/socket.h> /* Need to be after sys/types.h */
|
||||
|
@ -8,9 +8,6 @@
|
||||
#include <signal.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#ifdef HAVE_SYS_SIGNAL_H
|
||||
#include <sys/signal.h>
|
||||
#endif
|
||||
#include <sys/types.h>
|
||||
#ifdef HAVE_SYS_WAIT_H
|
||||
#include <sys/wait.h>
|
||||
|
@ -178,7 +178,7 @@ dopr(char *buffer, size_t maxlen, const char *format, va_list args_in)
|
||||
size_t currlen;
|
||||
va_list args;
|
||||
|
||||
VA_COPY(args, args_in);
|
||||
va_copy(args, args_in);
|
||||
|
||||
state = DP_S_DEFAULT;
|
||||
currlen = 0;
|
||||
@ -825,7 +825,7 @@ elinks_vasprintf(char **ptr, const char *format, va_list ap)
|
||||
int ret;
|
||||
va_list ap2;
|
||||
|
||||
VA_COPY(ap2, ap);
|
||||
va_copy(ap2, ap);
|
||||
|
||||
ret = vsnprintf(NULL, 0, format, ap2);
|
||||
if (ret <= 0) return ret;
|
||||
@ -842,7 +842,7 @@ elinks_vasprintf(char **ptr, const char *format, va_list ap)
|
||||
(*ptr) = (char *) malloc(ret + 1);
|
||||
if (!*ptr) return -1;
|
||||
|
||||
VA_COPY(ap2, ap);
|
||||
va_copy(ap2, ap);
|
||||
|
||||
return vsnprintf(*ptr, ret + 1, format, ap2);
|
||||
}
|
||||
|
@ -11,11 +11,11 @@
|
||||
|
||||
/* XXX: This is not quite the best place for it, perhaps. But do we have
|
||||
* a better one now? --pasky */
|
||||
#ifndef VA_COPY
|
||||
#ifdef HAVE_VA_COPY
|
||||
#define VA_COPY(dest, src) __va_copy(dest, src)
|
||||
#ifndef va_copy
|
||||
#ifdef __va_copy
|
||||
#define va_copy(dest, src) __va_copy(dest, src)
|
||||
#else
|
||||
#define VA_COPY(dest, src) (dest) = (src)
|
||||
#define va_copy(dest, src) (dest) = (src)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
@ -8,9 +8,6 @@
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include <sys/types.h> /* NetBSD flavour */
|
||||
#ifdef HAVE_SYS_SIGNAL_H
|
||||
#include <sys/signal.h>
|
||||
#endif
|
||||
#ifdef HAVE_FCNTL_H
|
||||
#include <fcntl.h> /* OS/2 needs this after sys/types.h */
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user