From 8cf335f1b3e14baa70d795b901e313a61cb4cec3 Mon Sep 17 00:00:00 2001 From: Tim Waugh Date: Mon, 15 May 2017 11:56:24 +0100 Subject: [PATCH] Don't use regerror() result as format string. --- patchutils-format-str.patch | 21 +++++++++++++++++++++ patchutils.spec | 5 ++++- 2 files changed, 25 insertions(+), 1 deletion(-) create mode 100644 patchutils-format-str.patch diff --git a/patchutils-format-str.patch b/patchutils-format-str.patch new file mode 100644 index 0000000..88ba8c6 --- /dev/null +++ b/patchutils-format-str.patch @@ -0,0 +1,21 @@ +diff -up patchutils-0.3.4/src/filterdiff.c.format-str patchutils-0.3.4/src/filterdiff.c +--- patchutils-0.3.4/src/filterdiff.c.format-str 2017-05-15 11:54:20.203918650 +0100 ++++ patchutils-0.3.4/src/filterdiff.c 2017-05-15 11:54:58.631833806 +0100 +@@ -1355,7 +1355,7 @@ read_regex_file (const char *file) + char errstr[300]; + regerror (err, ®ex[num_regex - 1], errstr, + sizeof (errstr)); +- error (EXIT_FAILURE, 0, errstr); ++ error (EXIT_FAILURE, 0, "%s", errstr); + exit (1); + } + } +@@ -1613,7 +1613,7 @@ int main (int argc, char *argv[]) + char errstr[300]; + regerror (err, ®ex[num_regex - 1], errstr, + sizeof (errstr)); +- error (EXIT_FAILURE, 0, errstr); ++ error (EXIT_FAILURE, 0, "%s", errstr); + exit (1); + } + } diff --git a/patchutils.spec b/patchutils.spec index acc8dee..2e25430 100644 --- a/patchutils.spec +++ b/patchutils.spec @@ -1,7 +1,7 @@ Summary: A collection of programs for manipulating patch files Name: patchutils Version: 0.3.4 -Release: 6%{?dist} +Release: 7%{?dist} License: GPLv2+ Group: Applications/System URL: http://cyberelk.net/tim/patchutils/ @@ -49,6 +49,9 @@ rm -rf %{buildroot} %{_mandir}/*/* %changelog +* Mon May 15 2017 Tim Waugh - 0.3.4-7 +- Don't use regerror() result as format string. + * Sat Feb 11 2017 Fedora Release Engineering - 0.3.4-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild