This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

boehm-gc support for s390 architecture


Hi,
the s390 boehm-gc support as part of the 3.1 branch doesn't compile for me, 
since va_list assignment is not portable in cordprnt.c. Attached is the patch 
I am using in Debian, but it is probably Linux specific. Does anyone know how 
to fix it portable?

Regards,
Gerhard


diff -urN gcc-20020401-bak/boehm-gc/cord/cordprnt.c 
gcc-20020401/boehm-gc/cord/cordprnt.c
--- gcc-20020401-bak/boehm-gc/cord/cordprnt.c	Tue Oct  2 19:40:38 2001
+++ gcc-20020401/boehm-gc/cord/cordprnt.c	Wed Apr  3 09:18:32 2002
@@ -255,12 +255,13 @@
             	/* Use standard sprintf to perform conversion */
             	{
             	    register char * buf;
-            	    va_list vsprintf_args = args;
+            	    va_list vsprintf_args;
             	    	/* The above does not appear to be sanctioned	*/
             	    	/* by the ANSI C standard.			*/
             	    int max_size = 0;
             	    int res;
             	    	
+            	    __va_copy(vsprintf_args, args);
             	    if (width == VARIABLE) width = va_arg(args, int);
             	    if (prec == VARIABLE) prec = va_arg(args, int);
             	    if (width != NONE) max_size = width;


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]