summaryrefslogtreecommitdiff
path: root/gl
diff options
context:
space:
mode:
authorPádraig Brady <P@draigBrady.com>2015-02-03 03:15:10 +0000
committerPádraig Brady <P@draigBrady.com>2015-02-03 10:18:28 +0000
commit658529a10e05d06524d5f591a08f04c04159b4cc (patch)
tree012a365fb870240694613f6a501ccf34b4080f49 /gl
parentbfb4f5c8b791fdcc3cdba87a5182fc684fa8cd24 (diff)
downloadcoreutils-658529a10e05d06524d5f591a08f04c04159b4cc.tar.gz
build: fix invalid gnulib patch
* gl/lib/tempname.c.diff: Fix recent breakage so it applies again. Invalid patch was noticed at http://hydra.nixos.org/eval/1172233 * cfg.mk: Exempt diff files from these "id_est" syntax checks. (sc_ensure_gl_diffs_apply): A new syntax check, to ensure all patches under gl/ apply cleanly. Note we use --fuzz=0 to check patches apply cleanly for safety, due to the patch(1) issue detailed in commit v8.21-117-g46f7e05 * gl/lib/regcomp.c.diff: Rediffed. * gl/lib/regex_internal.c.diff: Likewise. * gl/lib/regex_internal.h.diff: Likewise. * gl/lib/regexec.c.diff: Likewise. * gl/lib/tempname.h.diff: Likewise.
Diffstat (limited to 'gl')
-rw-r--r--gl/lib/regcomp.c.diff14
-rw-r--r--gl/lib/regex_internal.c.diff10
-rw-r--r--gl/lib/regex_internal.h.diff4
-rw-r--r--gl/lib/regexec.c.diff14
-rw-r--r--gl/lib/tempname.c.diff16
-rw-r--r--gl/lib/tempname.h.diff2
6 files changed, 30 insertions, 30 deletions
diff --git a/gl/lib/regcomp.c.diff b/gl/lib/regcomp.c.diff
index 9042a6e47..cc6649f2e 100644
--- a/gl/lib/regcomp.c.diff
+++ b/gl/lib/regcomp.c.diff
@@ -1,8 +1,8 @@
diff --git a/lib/regcomp.c b/lib/regcomp.c
-index 6d5525a..c9331d4 100644
+index 840220f..192632c 100644
--- a/lib/regcomp.c
+++ b/lib/regcomp.c
-@@ -539,7 +539,7 @@ regerror (errcode, preg, errbuf, errbuf_size)
+@@ -540,7 +540,7 @@ regerror (errcode, preg, errbuf, errbuf_size)
size_t errbuf_size;
#else /* size_t might promote */
size_t
@@ -11,7 +11,7 @@ index 6d5525a..c9331d4 100644
char *_Restrict_ errbuf, size_t errbuf_size)
#endif
{
-@@ -1421,7 +1421,7 @@ calc_first (void *extra, bin_tree_t *node)
+@@ -1427,7 +1427,7 @@ calc_first (void *extra, bin_tree_t *node)
/* Pass 2: compute NEXT on the tree. Preorder visit. */
static reg_errcode_t
@@ -20,7 +20,7 @@ index 6d5525a..c9331d4 100644
{
switch (node->token.type)
{
-@@ -2807,8 +2807,10 @@ build_range_exp (const reg_syntax_t syntax,
+@@ -2820,8 +2820,10 @@ build_range_exp (const reg_syntax_t syntax,
static reg_errcode_t
internal_function
# ifdef RE_ENABLE_I18N
@@ -33,7 +33,7 @@ index 6d5525a..c9331d4 100644
# else /* not RE_ENABLE_I18N */
build_collating_symbol (bitset_t sbcset, const unsigned char *name)
# endif /* not RE_ENABLE_I18N */
-@@ -3392,7 +3394,8 @@ parse_bracket_exp (re_string_t *regexp, re_dfa_t *dfa, re_token_t *token,
+@@ -3389,7 +3391,8 @@ parse_bracket_exp (re_string_t *regexp, re_dfa_t *dfa, re_token_t *token,
static reg_errcode_t
parse_bracket_element (bracket_elem_t *elem, re_string_t *regexp,
@@ -43,7 +43,7 @@ index 6d5525a..c9331d4 100644
reg_syntax_t syntax, bool accept_hyphen)
{
#ifdef RE_ENABLE_I18N
-@@ -3479,8 +3482,10 @@ parse_bracket_symbol (bracket_elem_t *elem, re_string_t *regexp,
+@@ -3476,8 +3479,10 @@ parse_bracket_symbol (bracket_elem_t *elem, re_string_t *regexp,
static reg_errcode_t
#ifdef RE_ENABLE_I18N
@@ -56,7 +56,7 @@ index 6d5525a..c9331d4 100644
#else /* not RE_ENABLE_I18N */
build_equiv_class (bitset_t sbcset, const unsigned char *name)
#endif /* not RE_ENABLE_I18N */
-@@ -3886,7 +3891,7 @@ free_token (re_token_t *node)
+@@ -3883,7 +3888,7 @@ free_token (re_token_t *node)
and its children. */
static reg_errcode_t
diff --git a/gl/lib/regex_internal.c.diff b/gl/lib/regex_internal.c.diff
index a27f67218..355cadb42 100644
--- a/gl/lib/regex_internal.c.diff
+++ b/gl/lib/regex_internal.c.diff
@@ -1,17 +1,17 @@
diff --git a/lib/regex_internal.c b/lib/regex_internal.c
-index 7e8c1bc..e68c9da 100644
+index 36ae6ab..c11ff09 100644
--- a/lib/regex_internal.c
+++ b/lib/regex_internal.c
-@@ -16,6 +16,8 @@
- You should have received a copy of the GNU General Public License along
- with this program; if not, see <http://www.gnu.org/licenses/>. */
+@@ -17,6 +17,8 @@
+ License along with the GNU C Library; if not, see
+ <http://www.gnu.org/licenses/>. */
+#include "verify.h"
+#include "intprops.h"
static void re_string_construct_common (const char *str, Idx len,
re_string_t *pstr,
RE_TRANSLATE_TYPE trans, bool icase,
-@@ -1393,7 +1395,10 @@ static void
+@@ -1389,7 +1391,10 @@ static void
internal_function
re_node_set_remove_at (re_node_set *set, Idx idx)
{
diff --git a/gl/lib/regex_internal.h.diff b/gl/lib/regex_internal.h.diff
index f410882c7..a4d78af21 100644
--- a/gl/lib/regex_internal.h.diff
+++ b/gl/lib/regex_internal.h.diff
@@ -1,8 +1,8 @@
diff --git a/lib/regex_internal.h b/lib/regex_internal.h
-index 439444c..7242084 100644
+index ff486bb..ff85ac8 100644
--- a/lib/regex_internal.h
+++ b/lib/regex_internal.h
-@@ -827,7 +827,8 @@ re_string_wchar_at (const re_string_t *pstr, Idx idx)
+@@ -863,7 +863,8 @@ re_string_wchar_at (const re_string_t *pstr, Idx idx)
# ifndef NOT_IN_libc
static int
internal_function __attribute__ ((pure, unused))
diff --git a/gl/lib/regexec.c.diff b/gl/lib/regexec.c.diff
index 897d24839..1aa3c2477 100644
--- a/gl/lib/regexec.c.diff
+++ b/gl/lib/regexec.c.diff
@@ -1,17 +1,17 @@
diff --git a/lib/regexec.c b/lib/regexec.c
-index 7d130a0..a58d454 100644
+index d3920c4..a8152b5 100644
--- a/lib/regexec.c
+++ b/lib/regexec.c
-@@ -16,6 +16,8 @@
- You should have received a copy of the GNU General Public License along
- with this program; if not, see <http://www.gnu.org/licenses/>. */
+@@ -17,6 +17,8 @@
+ License along with the GNU C Library; if not, see
+ <http://www.gnu.org/licenses/>. */
+#include "verify.h"
+#include "intprops.h"
static reg_errcode_t match_ctx_init (re_match_context_t *cache, int eflags,
Idx n) internal_function;
static void match_ctx_clean (re_match_context_t *mctx) internal_function;
-@@ -374,8 +376,11 @@ re_search_2_stub (struct re_pattern_buffer *bufp,
+@@ -373,8 +375,11 @@ re_search_2_stub (struct re_pattern_buffer *bufp,
Idx len = length1 + length2;
char *s = NULL;
@@ -25,7 +25,7 @@ index 7d130a0..a58d454 100644
/* Concatenate the strings. */
if (length2 > 0)
-@@ -426,11 +431,14 @@ re_search_stub (struct re_pattern_buffer *bufp,
+@@ -423,11 +428,14 @@ re_search_stub (struct re_pattern_buffer *bufp,
Idx last_start = start + range;
/* Check for out-of-range. */
@@ -42,4 +42,4 @@ index 7d130a0..a58d454 100644
+ else if (BE (/* last_start < 0 || */ (range < 0 && start <= last_start), 0))
last_start = 0;
- __libc_lock_lock (dfa->lock);
+ lock_lock (dfa->lock);
diff --git a/gl/lib/tempname.c.diff b/gl/lib/tempname.c.diff
index 7cf923043..5138df29b 100644
--- a/gl/lib/tempname.c.diff
+++ b/gl/lib/tempname.c.diff
@@ -1,5 +1,5 @@
diff --git a/lib/tempname.c b/lib/tempname.c
-index 26a38ce..5944ee0 100644
+index 088b224..e9a6c0c 100644
--- a/lib/tempname.c
+++ b/lib/tempname.c
@@ -20,6 +20,7 @@
@@ -18,7 +18,7 @@ index 26a38ce..5944ee0 100644
#include <stddef.h>
#include <stdlib.h>
#include <string.h>
-@@ -175,14 +177,21 @@ __path_search (char *tmpl, size_t tmpl_len, const char *dir, const char *pfx,
+@@ -172,14 +174,21 @@ __path_search (char *tmpl, size_t tmpl_len, const char *dir, const char *pfx,
}
#endif /* _LIBC */
@@ -33,7 +33,7 @@ index 26a38ce..5944ee0 100644
"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789";
/* Generate a temporary file name based on TMPL. TMPL must match the
-- rules for mk[s]temp (i.e., end in "XXXXXX", possibly with a suffix).
+- rules for mk[s]temp (i.e. end in "XXXXXX", possibly with a suffix).
+ rules for mk[s]temp (i.e., end in at least X_SUFFIX_LEN "X"s,
+ possibly with a suffix).
The name constructed does not exist at the time of the call to
@@ -42,7 +42,7 @@ index 26a38ce..5944ee0 100644
KIND may be one of:
__GT_NOCREATE: simply verify that the name does not exist
-@@ -193,23 +202,24 @@ static const char letters[] =
+@@ -190,23 +199,24 @@ static const char letters[] =
We use a clever algorithm to get hard-to-predict names. */
int
@@ -72,7 +72,7 @@ index 26a38ce..5944ee0 100644
#define ATTEMPTS_MIN (62 * 62 * 62)
/* The number of times to attempt to generate a temporary file. To
-@@ -221,43 +231,28 @@ __gen_tempname (char *tmpl, int suffixlen, int flags, int kind)
+@@ -218,43 +228,28 @@ __gen_tempname (char *tmpl, int suffixlen, int flags, int kind)
#endif
len = strlen (tmpl);
@@ -128,7 +128,7 @@ index 26a38ce..5944ee0 100644
switch (kind)
{
-@@ -272,7 +267,7 @@ __gen_tempname (char *tmpl, int suffixlen, int flags, int kind)
+@@ -269,7 +264,7 @@ __gen_tempname (char *tmpl, int suffixlen, int flags, int kind)
break;
case __GT_NOCREATE:
@@ -137,7 +137,7 @@ index 26a38ce..5944ee0 100644
succeeds if __xstat fails because the name does not exist.
Note the continue to bypass the common logic at the bottom
of the loop. */
-@@ -281,11 +276,15 @@ __gen_tempname (char *tmpl, int suffixlen, int flags, int kind)
+@@ -278,11 +273,15 @@ __gen_tempname (char *tmpl, int suffixlen, int flags, int kind)
if (errno == ENOENT)
{
__set_errno (save_errno);
@@ -156,7 +156,7 @@ index 26a38ce..5944ee0 100644
}
continue;
-@@ -297,13 +296,32 @@ __gen_tempname (char *tmpl, int suffixlen, int flags, int kind)
+@@ -294,13 +293,32 @@ __gen_tempname (char *tmpl, int suffixlen, int flags, int kind)
if (fd >= 0)
{
__set_errno (save_errno);
diff --git a/gl/lib/tempname.h.diff b/gl/lib/tempname.h.diff
index 2e885e185..ec70a473d 100644
--- a/gl/lib/tempname.h.diff
+++ b/gl/lib/tempname.h.diff
@@ -1,5 +1,5 @@
diff --git a/lib/tempname.h b/lib/tempname.h
-index 7972562..7ced9a9 100644
+index b560ee5..6e162c3 100644
--- a/lib/tempname.h
+++ b/lib/tempname.h
@@ -46,5 +46,7 @@