Mercurial > hg > octave-nkf > gnulib-hg
changeset 8975:b70a0b36c501
* m4/regex.m4 (gl_REGEX): Catch a bug with [[:alnum:]_-] reported by
Vin Shelton.
author | Paul Eggert <eggert@cs.ucla.edu> |
---|---|
date | Tue, 12 Jun 2007 17:44:37 +0000 |
parents | ad4d14c1737e |
children | ac9d2f4c619c |
files | ChangeLog m4/regex.m4 |
diffstat | 2 files changed, 17 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2007-06-12 Paul Eggert <eggert@cs.ucla.edu> + + * m4/regex.m4 (gl_REGEX): Catch a bug with [[:alnum:]_-] reported by + Vin Shelton. + 2007-06-11 Bruno Haible <bruno@clisp.org> * lib/printf-args.c (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Fix NULL
--- a/m4/regex.m4 +++ b/m4/regex.m4 @@ -1,4 +1,4 @@ -#serial 46 +#serial 47 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, # 2006, 2007 Free Software Foundation, Inc. @@ -137,6 +137,17 @@ if (re_search (®ex, "WXY", 3, 0, 3, ®s) < 0) return 1; + /* Catch a bug reported by Vin Shelton in + http://lists.gnu.org/archive/html/bug-coreutils/2007-06/msg00089.html + */ + re_set_syntax (RE_SYNTAX_POSIX_BASIC + & ~RE_CONTEXT_INVALID_DUP + & ~RE_NO_EMPTY_RANGES); + memset (®ex, 0, sizeof regex); + s = re_compile_pattern ("[[:alnum:]_-]\\\\+$", 16, ®ex); + if (s) + return 1; + /* REG_STARTEND was added to glibc on 2004-01-15. Reject older versions. */ if (! REG_STARTEND)