]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
build: update gnulib submodule to latest
authorPaul Eggert <eggert@cs.ucla.edu>
Tue, 27 Apr 2021 01:02:16 +0000 (18:02 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Tue, 27 Apr 2021 06:32:45 +0000 (23:32 -0700)
* src/csplit.c (load_buffer):
* src/pinky.c (create_fullname):
Use intprops-based checks rather than xalloc_oversized,
since Gnulib xalloc.h no longer includes xalloc-oversized.h.

gnulib
src/csplit.c
src/pinky.c

diff --git a/gnulib b/gnulib
index e54b645fc6b8422562327443bda575c65d931fbd..354b9691accd00a531358b652689ce7f580fbe54 160000 (submodule)
--- a/gnulib
+++ b/gnulib
@@ -1 +1 @@
-Subproject commit e54b645fc6b8422562327443bda575c65d931fbd
+Subproject commit 354b9691accd00a531358b652689ce7f580fbe54
index ee9aa650322f02dab54a0086598385139e539fe2..79bd034e3f5a0d1ecb399237f08ca5819bdcceaa 100644 (file)
@@ -518,9 +518,8 @@ load_buffer (void)
       if (lines_found || have_read_eof)
         break;
 
-      if (xalloc_oversized (2, b->bytes_alloc))
+      if (INT_MULTIPLY_WRAPV (b->bytes_alloc, 2, &bytes_wanted))
         xalloc_die ();
-      bytes_wanted = 2 * b->bytes_alloc;
       free_buffer (b);
       free (b);
     }
index 23a43f5e4f431172c28a7f86af408f04469d22ef..6fea94923c54c787763157ef638d618a23aee4f1 100644 (file)
@@ -110,9 +110,9 @@ create_fullname (char const *gecos_name, char const *user_name)
   if (ampersands != 0)
     {
       size_t ulen = strlen (user_name);
-      size_t product = ampersands * ulen;
-      rsize += product - ampersands;
-      if (xalloc_oversized (ulen, ampersands) || rsize < product)
+      size_t product;
+      if (INT_MULTIPLY_WRAPV (ulen, ampersands - 1, &product)
+          || INT_ADD_WRAPV (rsize, product, &rsize))
         xalloc_die ();
     }