projects
/
gnulib.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
d3da3fd
)
(jm_INCLUDED_REGEX): Detect broken re_search in e.g. glibc-2.2.93.
author
Jim Meyering
<jim@meyering.net>
Sun, 2 Feb 2003 18:27:48 +0000
(18:27 +0000)
committer
Jim Meyering
<jim@meyering.net>
Sun, 2 Feb 2003 18:27:48 +0000
(18:27 +0000)
m4/regex.m4
patch
|
blob
|
history
diff --git
a/m4/regex.m4
b/m4/regex.m4
index
a31ef2c
..
3ba6166
100644
(file)
--- a/
m4/regex.m4
+++ b/
m4/regex.m4
@@
-1,4
+1,4
@@
-#serial 1
4
+#serial 1
5
dnl Initially derived from code in GNU grep.
dnl Mostly written by Jim Meyering.
dnl Initially derived from code in GNU grep.
dnl Mostly written by Jim Meyering.
@@
-60,6
+60,16
@@
AC_DEFUN([jm_INCLUDED_REGEX],
if (re_match (®ex, "an", 2, 0, ®s) != 2)
exit (1);
if (re_match (®ex, "an", 2, 0, ®s) != 2)
exit (1);
+ memset (®ex, 0, sizeof (regex));
+ s = re_compile_pattern ("x", 1, ®ex);
+ if (s)
+ exit (1);
+
+ /* The version of regex.c in e.g. GNU libc-2.2.93 didn't
+ work with a negative RANGE argument. */
+ if (re_search (®ex, "wxy", 3, 2, -2, ®s) != 1)
+ exit (1);
+
exit (0);
}
],
exit (0);
}
],