diff --git a/winsup/mingw/ChangeLog b/winsup/mingw/ChangeLog index c704a2eac..983e2b23c 100644 --- a/winsup/mingw/ChangeLog +++ b/winsup/mingw/ChangeLog @@ -1,3 +1,13 @@ +2008-09-19 Keith Marshall + + Fix MinGW-Bug [2117379]. + (Reported by Peiyuan Song). + + * include/stdio.h (__argv): Replace all references in function + prototype argument lists and inline function local variables, with ... + (__local_argv): ...this, to avoid potential conflict with ... + * include/stdlib (__argv): ...this #defined macro. + 2008-09-07 Chris Sutcliffe * include/_mingw.h: Increment version to 3.15. diff --git a/winsup/mingw/include/stdio.h b/winsup/mingw/include/stdio.h index c05b1b1dd..1765bed9d 100644 --- a/winsup/mingw/include/stdio.h +++ b/winsup/mingw/include/stdio.h @@ -242,9 +242,9 @@ __mingw_stdio_redirect__ int fprintf (FILE *__stream, const char *__format, ...) { register int __retval; - __builtin_va_list __argv; __builtin_va_start( __argv, __format ); - __retval = __mingw_vfprintf( __stream, __format, __argv ); - __builtin_va_end( __argv ); + __builtin_va_list __local_argv; __builtin_va_start( __local_argv, __format ); + __retval = __mingw_vfprintf( __stream, __format, __local_argv ); + __builtin_va_end( __local_argv ); return __retval; } @@ -252,9 +252,9 @@ __mingw_stdio_redirect__ int printf (const char *__format, ...) { register int __retval; - __builtin_va_list __argv; __builtin_va_start( __argv, __format ); - __retval = __mingw_vprintf( __format, __argv ); - __builtin_va_end( __argv ); + __builtin_va_list __local_argv; __builtin_va_start( __local_argv, __format ); + __retval = __mingw_vprintf( __format, __local_argv ); + __builtin_va_end( __local_argv ); return __retval; } @@ -262,28 +262,28 @@ __mingw_stdio_redirect__ int sprintf (char *__stream, const char *__format, ...) { register int __retval; - __builtin_va_list __argv; __builtin_va_start( __argv, __format ); - __retval = __mingw_vsprintf( __stream, __format, __argv ); - __builtin_va_end( __argv ); + __builtin_va_list __local_argv; __builtin_va_start( __local_argv, __format ); + __retval = __mingw_vsprintf( __stream, __format, __local_argv ); + __builtin_va_end( __local_argv ); return __retval; } __mingw_stdio_redirect__ -int vfprintf (FILE *__stream, const char *__format, __VALIST __argv) +int vfprintf (FILE *__stream, const char *__format, __VALIST __local_argv) { - return __mingw_vfprintf( __stream, __format, __argv ); + return __mingw_vfprintf( __stream, __format, __local_argv ); } __mingw_stdio_redirect__ -int vprintf (const char *__format, __VALIST __argv) +int vprintf (const char *__format, __VALIST __local_argv) { - return __mingw_vprintf( __format, __argv ); + return __mingw_vprintf( __format, __local_argv ); } __mingw_stdio_redirect__ -int vsprintf (char *__stream, const char *__format, __VALIST __argv) +int vsprintf (char *__stream, const char *__format, __VALIST __local_argv) { - return __mingw_vsprintf( __stream, __format, __argv ); + return __mingw_vsprintf( __stream, __format, __local_argv ); } #else