Commit f74595aa authored by Paul Eggert's avatar Paul Eggert

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.
parent 07d88279
Pipeline #297 failed with stage
in 9 seconds
......@@ -2,7 +2,7 @@
# Attempt to guess a canonical system name.
# Copyright 1992-2018 Free Software Foundation, Inc.
timestamp='2018-11-28'
timestamp='2018-12-07'
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
......@@ -96,8 +96,7 @@ fi
tmp=
# shellcheck disable=SC2172
trap 'test -z "$tmp" || rm -fr "$tmp"' 1 2 13 15
trap 'exitcode=$?; test -z "$tmp" || rm -fr "$tmp"; exit $exitcode' 0
trap 'test -z "$tmp" || rm -fr "$tmp"' 0 1 2 13 15
set_cc_for_build() {
: "${TMPDIR=/tmp}"
......
......@@ -2,7 +2,7 @@
# Configuration validation subroutine script.
# Copyright 1992-2018 Free Software Foundation, Inc.
timestamp='2018-11-28'
timestamp='2018-12-16'
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
......@@ -111,7 +111,7 @@ case $# in
esac
# Split fields of configuration type
IFS="-" read -r field1 field2 field3 field4 <<EOF
IFS="-" read field1 field2 field3 field4 <<EOF
$1
EOF
......@@ -918,7 +918,7 @@ case $basic_machine in
;;
*-*)
IFS="-" read -r cpu vendor <<EOF
IFS="-" read cpu vendor <<EOF
$basic_machine
EOF
;;
......
......@@ -139,7 +139,7 @@
Headers that should use flexible arrays only if they're "real"
(e.g. only if they won't affect sizeof()) should test
#if __glibc_c99_flexarr_available. */
#if defined __STDC_VERSION__ && __STDC_VERSION__ >= 199901L
#if defined __STDC_VERSION__ && __STDC_VERSION__ >= 199901L && !defined __HP_cc
# define __flexarr []
# define __glibc_c99_flexarr_available 1
#elif __GNUC_PREREQ (2,97)
......
......@@ -185,7 +185,7 @@ npgettext_aux (const char *domain,
#include <string.h>
#if (((__GNUC__ >= 3 || __GNUG__ >= 2) && !defined __STRICT_ANSI__) \
/* || __STDC_VERSION__ == 199901L
/* || (__STDC_VERSION__ == 199901L && !defined __HP_cc)
|| (__STDC_VERSION__ >= 201112L && !defined __STDC_NO_VLA__) */ )
# define _LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS 1
#else
......
......@@ -34,6 +34,7 @@ struct tm *localtime_buffer_addr = &tm_zero_buffer;
struct tm *
rpl_localtime (time_t const *timep)
#undef localtime
{
struct tm *tm = localtime (timep);
......@@ -46,6 +47,7 @@ rpl_localtime (time_t const *timep)
/* Same as above, since gmtime and localtime use the same buffer. */
struct tm *
rpl_gmtime (time_t const *timep)
#undef gmtime
{
struct tm *tm = gmtime (timep);
......
......@@ -2783,8 +2783,11 @@ get_subexp (re_match_context_t *mctx, Idx bkref_node, Idx bkref_str_idx)
return REG_ESPACE;
err = get_subexp_sub (mctx, sub_top, sub_last, bkref_node,
bkref_str_idx);
buf = (const char *) re_string_get_buffer (&mctx->input);
if (err == REG_NOMATCH)
continue;
if (__glibc_unlikely (err != REG_NOERROR))
return err;
}
}
return REG_NOERROR;
......
# 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 (&regex, 0, sizeof regex);
s = re_compile_pattern ("0|()0|\\1|0", 10, &regex);
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
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment