From b4499a7ca68fc8cd2f0e9d5868d2371debe7b9cd Mon Sep 17 00:00:00 2001 From: zhangruifang2020 Date: Tue, 18 Oct 2022 14:18:17 +0800 Subject: [PATCH] fix stray blanking of config file char --- autogen.spec | 7 +++- ...x-stray-blanking-of-config-file-char.patch | 38 +++++++++++++++++++ 2 files changed, 44 insertions(+), 1 deletion(-) create mode 100644 backport-fix-stray-blanking-of-config-file-char.patch diff --git a/autogen.spec b/autogen.spec index 75f3bb6..e485681 100644 --- a/autogen.spec +++ b/autogen.spec @@ -1,6 +1,6 @@ Name: autogen Version: 5.18.16 -Release: 2 +Release: 3 License: GPLv2+ and GPLv3+ Summary: Automated text file generator URL: http://www.gnu.org/software/autogen/ @@ -8,6 +8,8 @@ Provides: autogen-libopts Obsoletes: autogen-libopts Source0: http://ftp.gnu.org/gnu/autogen/rel%{version}/%{name}-%{version}.tar.xz +Patch0: backport-fix-stray-blanking-of-config-file-char.patch + BuildRequires: gcc guile-devel libtool libxml2-devel BuildRequires: perl-generators BuildRequires: chrpath @@ -102,6 +104,9 @@ echo "%{_libdir}" > $RPM_BUILD_ROOT/etc/ld.so.conf.d/%{name}-%{_arch}.conf %exclude %{_infodir}/dir %changelog +* Tue Oct 18 2022 zhangruifang - 5.18.16-3 +- fix stray blanking of config file char + * Thu Jul 28 2022 zoulin - 5.18.16-2 - remove rpath and runpath of exec files and libraries diff --git a/backport-fix-stray-blanking-of-config-file-char.patch b/backport-fix-stray-blanking-of-config-file-char.patch new file mode 100644 index 0000000..50a956e --- /dev/null +++ b/backport-fix-stray-blanking-of-config-file-char.patch @@ -0,0 +1,38 @@ +From 3b33eb2fc09a2d7221da6bc7159f374fdef8906a Mon Sep 17 00:00:00 2001 +From: Bruce Korb +Date: Fri, 6 Sep 2019 08:28:00 -0700 +Subject: [PATCH] fix stray blanking of config file char + +* autoopts/configfile.c (trim_xml_text): remove unnecessary and + occasionally destructive blanking of first character. +--- + autoopts/configfile.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/autoopts/configfile.c b/autoopts/configfile.c +index 783a9d8a..e8f557ad 100644 +--- a/autoopts/configfile.c ++++ b/autoopts/configfile.c +@@ -802,10 +802,9 @@ trim_xml_text(char * intxt, char const * pznm, tOptionLoadMode mode) + pz[1] = '/'; + memcpy(pz+2, pznm, nm_len); + nm_len += 2; +- pz[nm_len++] = '>'; ++ pz[nm_len++] = '>'; // nm_len is now length of end mark + pz[nm_len] = NUL; + +- *intxt = ' '; + etext = strstr(intxt, pz); + if (pz != z) AGFREE(pz); + } +@@ -825,6 +824,7 @@ trim_xml_text(char * intxt, char const * pznm, tOptionLoadMode mode) + } + + /** ++ * process hex and amphersand encoded characters. + */ + static void + cook_xml_text(char * pzData) +-- +2.27.0 + -- Gitee