On linux use the va_copy() func for variable arugment copying
authorPeter Howkins <flibble@users.sourceforge.net>
Mon, 12 Mar 2012 16:24:24 +0000 (16:24 +0000)
committerPeter Howkins <flibble@users.sourceforge.net>
Mon, 12 Mar 2012 16:24:24 +0000 (16:24 +0000)
cde/programs/dtappbuilder/src/abmf/write_c.c

index 5e7245683d6ac7f0a84b2786863ac9ae32efecbd..6b49fa493cd155354b616b29e9dac845e3508673 100644 (file)
@@ -351,9 +351,13 @@ write_func_def_params(
 )
 {
 #ifdef __ppc
-#define va_start_params() __va_copy(params, va_params)
+# define va_start_params() __va_copy(params, va_params)
 #else
-#define va_start_params() (params = va_params)
+# if defined(linux)
+#  define va_start_params()  va_copy(params, va_params)
+# else
+#  define va_start_params() (params = va_params)
+# endif
 #endif
 #define va_end_params() (0)
     va_list    params;