diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index cf5d836f325..4fc63fa5b1a 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,8 @@ +2014-05-08 Paolo Carlini + + * acinclude.m4 ([GLIBCXX_ENABLE_C99]): Avoid -Wwrite-strings warning. + * configure: Regenerate. + 2014-05-07 Jonathan Wakely PR libstdc++/61023 diff --git a/libstdc++-v3/acinclude.m4 b/libstdc++-v3/acinclude.m4 index 437221f3ab1..cbce2ae4e5b 100644 --- a/libstdc++-v3/acinclude.m4 +++ b/libstdc++-v3/acinclude.m4 @@ -1052,8 +1052,8 @@ AC_DEFUN([GLIBCXX_ENABLE_C99], [ vscanf("%i", args); vsnprintf(fmt, 0, "%i", args); vsscanf(fmt, "%i", args); - }], - [snprintf("12", 0, "%i");], + snprintf(fmt, 0, "%i"); + }], [], [glibcxx_cv_c99_stdio=yes], [glibcxx_cv_c99_stdio=no]) ]) AC_MSG_RESULT($glibcxx_cv_c99_stdio) diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure index 9b842c70937..c481db6028b 100755 --- a/libstdc++-v3/configure +++ b/libstdc++-v3/configure @@ -16900,11 +16900,12 @@ else vscanf("%i", args); vsnprintf(fmt, 0, "%i", args); vsscanf(fmt, "%i", args); + snprintf(fmt, 0, "%i"); } int main () { -snprintf("12", 0, "%i"); + ; return 0; } @@ -16930,11 +16931,12 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext vscanf("%i", args); vsnprintf(fmt, 0, "%i", args); vsscanf(fmt, "%i", args); + snprintf(fmt, 0, "%i"); } int main () { -snprintf("12", 0, "%i"); + ; return 0; }