From 212dd804bd51ed406b546164f1c7e90f484f8a4f Mon Sep 17 00:00:00 2001 From: "Todd C. Miller" Date: Wed, 23 Oct 2002 15:38:17 +0000 Subject: Add a trivial va_copy() macro to all architectures but powerpc (which I will leave for Dale since it needs special handling). From NetBSD (and same as sparc64). espie@ OK --- sys/arch/sparc/include/stdarg.h | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'sys/arch/sparc') diff --git a/sys/arch/sparc/include/stdarg.h b/sys/arch/sparc/include/stdarg.h index 311ec168f3f..8647edb1fc8 100644 --- a/sys/arch/sparc/include/stdarg.h +++ b/sys/arch/sparc/include/stdarg.h @@ -1,4 +1,4 @@ -/* $OpenBSD: stdarg.h,v 1.4 1997/08/08 08:26:50 downsj Exp $ */ +/* $OpenBSD: stdarg.h,v 1.5 2002/10/23 15:38:16 millert Exp $ */ /* $NetBSD: stdarg.h,v 1.10 1996/12/27 20:55:28 pk Exp $ */ /* @@ -107,6 +107,13 @@ typedef _BSD_VA_LIST_ va_list; *__va_arg(ap, type *) : __va_size(type) == 8 ? \ __va_8byte(ap, type) : __va_arg(ap, type)) +#if !defined(_ANSI_SOURCE) && \ + (!defined(_POSIX_C_SOURCE) && !defined(_XOPEN_SOURCE) || \ + defined(_ISOC99_SOURCE) || (__STDC_VERSION__ - 0) >= 199901L) +#define va_copy(dest, src) \ + ((dest) = (src)) +#endif + #define va_end(ap) ((void)0) #endif /* !_SPARC_STDARG_H_ */ -- cgit v1.2.3