From 61253938ec1b6ca8a9f8d7fd62e869584a986c8b Mon Sep 17 00:00:00 2001 From: CentOS Sources Date: Jun 24 2021 04:21:46 +0000 Subject: import e2fsprogs-1.45.6-2.el8 --- diff --git a/SOURCES/e2fsprogs-1.45.6-mke2fs-Escape-double-quotes-when-parsing-mke2fs.conf.patch b/SOURCES/e2fsprogs-1.45.6-mke2fs-Escape-double-quotes-when-parsing-mke2fs.conf.patch new file mode 100644 index 0000000..471b4d5 --- /dev/null +++ b/SOURCES/e2fsprogs-1.45.6-mke2fs-Escape-double-quotes-when-parsing-mke2fs.conf.patch @@ -0,0 +1,52 @@ +From 6fa8edd0fde7a540b41d78e45743208c8edab0b1 Mon Sep 17 00:00:00 2001 +From: Lukas Czerner +Date: Mon, 2 Nov 2020 15:26:31 +0100 +Subject: [PATCH] mke2fs: Escape double quotes when parsing mke2fs.conf + +Currently, when constructing the configuration pseudo-file using +the profile-to-c.awk script we will just pass the double quotes as they +appear in the mke2fs.conf. + +This is problematic, because the resulting default_profile.c will either +fail to compile because of syntax error, or leave the resulting +configuration invalid. + +It can be reproduced by adding the following line somewhere into +mke2fs.conf configuration and forcing mke2fs to use the +configuration by specifying nonexistent mke2fs.conf + +MKE2FS_CONFIG="nonexistent" ./misc/mke2fs -T ext4 /dev/device + +default_mntopts = "acl,user_xattr" +^ this will fail to compile + +default_mntopts = "" +^ this will result in invalid config file + +Syntax error in mke2fs config file (, line #4) + Unknown code prof 17 + +Fix it by escaping the double quotes with a backslash in +profile-to-c.awk script. + +Signed-off-by: Lukas Czerner +Signed-off-by: Theodore Ts'o +--- + misc/profile-to-c.awk | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/misc/profile-to-c.awk b/misc/profile-to-c.awk +index f964efd6..814f7236 100644 +--- a/misc/profile-to-c.awk ++++ b/misc/profile-to-c.awk +@@ -4,6 +4,7 @@ BEGIN { + } + + { ++ gsub("\"","\\\"",$0); + printf(" \"%s\\n\"\n", $0); + } + +-- +2.26.3 + diff --git a/SPECS/e2fsprogs.spec b/SPECS/e2fsprogs.spec index 6cc8085..b0e69d0 100644 --- a/SPECS/e2fsprogs.spec +++ b/SPECS/e2fsprogs.spec @@ -1,7 +1,7 @@ Summary: Utilities for managing ext2, ext3, and ext4 file systems Name: e2fsprogs Version: 1.45.6 -Release: 1%{?dist} +Release: 2%{?dist} # License tags based on COPYING file distinctions for various components License: GPLv2 @@ -34,6 +34,7 @@ Patch3: e2fsprogs-1.45.6-man-Add-note-about-RHEL8-supported-features-and-moun.pa Patch4: e2fsprogs-1.45.6-Revert-libext2fs-revamp-bitmap-types-to-fix-LTO-warn.patch Patch5: e2fsprogs-1.45.6-Revert-libext2fs-hide-struct-ext2fs_hashmap-as-an-in.patch Patch6: e2fsprogs-1.45.6-ext2fs-fix-ABI-change-in-the-struct_ext2_filsys-stru.patch +Patch7: e2fsprogs-1.45.6-mke2fs-Escape-double-quotes-when-parsing-mke2fs.conf.patch %description The e2fsprogs package contains a number of utilities for creating, @@ -159,6 +160,7 @@ It was originally inspired by the Multics SubSystem library. %patch4 -p1 %patch5 -p1 %patch6 -p1 +%patch7 -p1 %build %configure CFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing" \ @@ -321,7 +323,10 @@ exit 0 %{_libdir}/pkgconfig/ss.pc %changelog -* Wed Jun 03 2020 Lukas Czerner 1.45.6-5 +* Thu Jun 17 2021 Lukas Czerner 1.45.6-2 +- Fix internal configuration pseudo file (#1889464) + +* Wed Jun 03 2020 Lukas Czerner 1.45.6-1 - Rebase to the upstream release 1.45.6 (#1843548) * Tue Jan 14 2020 Lukas Czerner 1.45.4-3