[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Configure problem when compiling with -D_FORTIFY_SOURCE
From: |
Bruno Haible |
Subject: |
Re: Configure problem when compiling with -D_FORTIFY_SOURCE |
Date: |
Sun, 16 Sep 2007 13:41:46 +0200 |
User-agent: |
KMail/1.5.4 |
Greg Schafer wrote:
> Size of 10000 seems to work. Size of 1000 doesn't. Using asprintf also
> seems to not crash with a size of 100.
OK, then the bug is in gnulib's tests, not in glibc. Thanks for these tests.
I'm applying this:
2007-09-16 Bruno Haible <address@hidden>
* m4/printf.m4 (gl_PRINTF_LONG_DOUBLE, gl_PRINTF_INFINITE,
gl_PRINTF_INFINITE_LONG_DOUBLE): Increase buf's size from 100 to 10000.
Needed on glibc-2.6.1 with -fstack-protector -D_FORTIFY_SOURCE=2.
Reported by Greg Schafer <address@hidden>.
--- m4/printf.m4 13 Jun 2007 01:28:35 -0000 1.35
+++ m4/printf.m4 16 Sep 2007 11:40:01 -0000
@@ -1,4 +1,4 @@
-# printf.m4 serial 15
+# printf.m4 serial 16
dnl Copyright (C) 2003, 2007 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -95,7 +95,7 @@
AC_TRY_RUN([
#include <stdio.h>
#include <string.h>
-static char buf[100];
+static char buf[10000];
int main ()
{
buf[0] = '\0';
@@ -156,7 +156,7 @@
}
return 0;
}
-static char buf[100];
+static char buf[10000];
static double zero = 0.0;
int main ()
{
@@ -261,7 +261,7 @@
}
return 0;
}
-static char buf[100];
+static char buf[10000];
static long double zeroL = 0.0L;
int main ()
{