bug-grep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

dfa.c order of include problem


From: Aharon Robbins
Subject: dfa.c order of include problem
Date: Thu, 31 Jan 2013 20:10:30 +0200
User-agent: Heirloom mailx 12.5 6/20/10

Hello All.

On systems where limits.h defines RE_DUP_MAX to be very small (such as
OpenVMS, which defines it to be -1) compiling a regexp can fail.

Although <regex.h> undefs and redefines RE_DUP_MAX, it's included too
early in the process. I am pushing the following change to gawk's copy
of dfa.c. I submit it for your review, as well.

Thanks,

Arnold
-------------------------------------
diff --git a/dfa.c b/dfa.c
index 8782e46..88d34d5 100644
--- a/dfa.c
+++ b/dfa.c
@@ -22,8 +22,6 @@
 
 #include <config.h>
 
-#include "dfa.h"
-
 #include <assert.h>
 #include <ctype.h>
 #include <stdio.h>
@@ -45,6 +43,8 @@
 #include "missing_d/gawkbool.h"
 #endif /* HAVE_STDBOOL_H */
 
+#include "dfa.h"
+
 
 #define STREQ(a, b) (strcmp (a, b) == 0)
 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]