|
From: | Jaap Haitsma |
Subject: | AC_FUNC_ALLOCA generates warning (problem with -Werror) |
Date: | Mon, 05 Jun 2006 23:27:16 +0200 |
Hi AC_FUNC_ALLOCA generates the following code #include <alloca.h> int main () { char *p = (char *) alloca (2 * sizeof (int)); ; return 0; } This generates a warning that the variable p is never used. This is a problem when you run configure with CFLAG="-Werror". Compilation of the above code will fail. This can be easily solved by adding the following line for (;&p!=0;) {/*Use p so we do not generate a warning */} Jaap
[Prev in Thread] | Current Thread | [Next in Thread] |