[git commit nptl] regex: convert #if to #ifdef

Mike Frysinger vapier at gentoo.org
Wed Aug 19 11:29:41 UTC 2009


commit: http://git.uclibc.org/uClibc/commit/?id=cda754758c48b034c71140204d5ee1400d2d9478
branch: http://git.uclibc.org/uClibc/commit/?id=refs/heads/nptl

Avoid gcc warnings about #if statements with defines that aren't defined.

Signed-off-by: Mike Frysinger <vapier at gentoo.org>
Signed-off-by: Austin Foxley <austinf at cetoncorp.com>
---
 libc/misc/regex/regex_internal.c |    2 +-
 libc/misc/regex/regex_internal.h |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/libc/misc/regex/regex_internal.c b/libc/misc/regex/regex_internal.c
index 4939852..de640e0 100644
--- a/libc/misc/regex/regex_internal.c
+++ b/libc/misc/regex/regex_internal.c
@@ -602,7 +602,7 @@ re_string_reconstruct (re_string_t *pstr, int idx, int eflags)
 		     pstr->valid_len - offset);
 	  pstr->valid_len -= offset;
 	  pstr->valid_raw_len -= offset;
-#if DEBUG
+#ifdef DEBUG
 	  assert (pstr->valid_len > 0);
 #endif
 	}
diff --git a/libc/misc/regex/regex_internal.h b/libc/misc/regex/regex_internal.h
index 85efe66..03f08bf 100644
--- a/libc/misc/regex/regex_internal.h
+++ b/libc/misc/regex/regex_internal.h
@@ -361,7 +361,7 @@ static unsigned int re_string_context_at (const re_string_t *input, int idx,
 #include <alloca.h>
 
 #if 1
-# if HAVE_ALLOCA
+# ifdef HAVE_ALLOCA
 /* The OS usually guarantees only one guard page at the bottom of the stack,
    and a page size can be as small as 4096 bytes.  So we cannot safely
    allocate anything larger than 4096 bytes.  Also care for the possibility
-- 
1.6.3.3



More information about the uClibc-cvs mailing list