From f5d1672ab557fe5436ce3b57f173a4117405fca1 Mon Sep 17 00:00:00 2001 From: CentOS Sources Date: Oct 15 2022 04:12:01 +0000 Subject: import coreutils-8.30-14.el8 --- diff --git a/SOURCES/coreutils-i18n-expand-unexpand.patch b/SOURCES/coreutils-i18n-expand-unexpand.patch index b5f571f..8fc8dff 100644 --- a/SOURCES/coreutils-i18n-expand-unexpand.patch +++ b/SOURCES/coreutils-i18n-expand-unexpand.patch @@ -572,16 +572,18 @@ index 7801274..569a7ee 100644 { /* Go back one column, and force recalculation of the next tab stop. */ -@@ -221,7 +235,7 @@ unexpand (void) +@@ -221,16 +235,20 @@ unexpand (void) } else { - column++; +- if (!column) ++ const uintmax_t orig_column = column; + column += mb_width (c); - if (!column) ++ if (column < orig_column) die (EXIT_FAILURE, 0, _("input line is too long")); } -@@ -229,8 +243,11 @@ unexpand (void) + if (pending) { if (pending > 1 && one_blank_before_tab_stop) @@ -595,7 +597,7 @@ index 7801274..569a7ee 100644 die (EXIT_FAILURE, errno, _("write error")); pending = 0; one_blank_before_tab_stop = false; -@@ -240,16 +257,17 @@ unexpand (void) +@@ -240,16 +258,17 @@ unexpand (void) convert &= convert_entire_line || blank; } diff --git a/SOURCES/coreutils-i18n-fix-unexpand.patch b/SOURCES/coreutils-i18n-fix-unexpand.patch deleted file mode 100644 index f0c347c..0000000 --- a/SOURCES/coreutils-i18n-fix-unexpand.patch +++ /dev/null @@ -1,28 +0,0 @@ -From 02424bfcd719bbaa695f4e1c3ef17ad91b0d23c0 Mon Sep 17 00:00:00 2001 -From: Lubomir Rintel -Date: Thu, 28 Jan 2016 20:57:22 +0100 -Subject: [PATCH] unexpand: fix blank line handling - - echo '' |./src/unexpand -a - -Really? ---- - src/unexpand.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/unexpand.c b/src/unexpand.c -index 569a7ee..3bbbd66 100644 ---- a/src/unexpand.c -+++ b/src/unexpand.c -@@ -233,7 +233,7 @@ unexpand (void) - next_tab_column = column; - tab_index -= !!tab_index; - } -- else -+ else if (!mb_iseq (c, '\n')) - { - column += mb_width (c); - if (!column) --- -2.7.4 - diff --git a/SPECS/coreutils.spec b/SPECS/coreutils.spec index aa39240..fb99c57 100644 --- a/SPECS/coreutils.spec +++ b/SPECS/coreutils.spec @@ -1,7 +1,7 @@ Summary: A set of basic GNU tools commonly used in shell scripts Name: coreutils Version: 8.30 -Release: 13%{?dist} +Release: 14%{?dist} License: GPLv3+ Group: System Environment/Base Url: https://www.gnu.org/software/coreutils/ @@ -85,8 +85,6 @@ Patch800: coreutils-i18n.patch Patch801: coreutils-i18n-expand-unexpand.patch # i18n patch for cut - old version - used Patch804: coreutils-i18n-cut-old.patch -# The unexpand patch above is not correct. Sent to the patch authors -Patch803: coreutils-i18n-fix-unexpand.patch #(un)expand - allow multiple files on input - broken by patch 801 Patch805: coreutils-i18n-fix2-expand-unexpand.patch #(un)expand - test BOM headers @@ -292,6 +290,9 @@ fi %license COPYING %changelog +* Mon Aug 01 2022 Kamil Dudka - 8.30-14 +- prevent unexpand from failing on control characters (#2112870) + * Tue Mar 01 2022 Kamil Dudka - 8.30-13 - ls, stat: avoid triggering automounts (#2044981) - make `df --direct` work again (#2058686)