diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2018-12-16 08:11:35 -0800 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2018-12-16 08:12:22 -0800 |
commit | f74595aace4b1240402562b0073b06c170969327 (patch) | |
tree | cd50bca64305e2fca5d4fa518e102e530a8b54ef /m4 | |
parent | 07d8827946f9364180f18d6842acc80f0997ed75 (diff) | |
download | emacs-f74595aace4b1240402562b0073b06c170969327.tar.gz |
Update from Gnulib
This incorporates:
2018-12-16 regex: propagate fix for glibc bug 18040
2018-12-16 obstack, libc-config: Support HP-UX cc in C99 mode
2018-12-15 regex: work around a bug in glibc-2.27 and prior
2018-12-13 localtime-buffer: Avoid endless recursion
* build-aux/config.guess, build-aux/config.sub, lib/cdefs.h:
* lib/gettext.h, lib/localtime-buffer.c, lib/regexec.c, m4/regex.m4:
Copy from Gnulib.
Diffstat (limited to 'm4')
-rw-r--r-- | m4/regex.m4 | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/m4/regex.m4 b/m4/regex.m4 index 055d71b5aaa..3a39b1a2044 100644 --- a/m4/regex.m4 +++ b/m4/regex.m4 @@ -1,4 +1,4 @@ -# serial 67 +# serial 68 # Copyright (C) 1996-2001, 2003-2018 Free Software Foundation, Inc. # @@ -213,6 +213,17 @@ AC_DEFUN([gl_REGEX], if (! REG_STARTEND) result |= 64; + /* Matching with the compiled form of this regexp would provoke + an assertion failure prior to glibc-2.28: + regexec.c:1375: pop_fail_stack: Assertion 'num >= 0' failed + With glibc-2.28, compilation fails and reports the invalid + back reference. */ + re_set_syntax (RE_SYNTAX_POSIX_EGREP); + memset (®ex, 0, sizeof regex); + s = re_compile_pattern ("0|()0|\\1|0", 10, ®ex); + if (!s || strcmp (s, "Invalid back reference")) + result |= 64; + #if 0 /* It would be nice to reject hosts whose regoff_t values are too narrow (including glibc on hosts with 64-bit ptrdiff_t and |