[packages/coreutils] - fix format string warning

baggins baggins at pld-linux.org
Tue Dec 18 00:06:17 CET 2012


commit 5b496f544d816a66ae486da369837a1d1e7b75ef
Author: Jan Rękorajski <baggins at pld-linux.org>
Date:   Tue Dec 18 00:05:49 2012 +0100

    - fix format string warning

 coreutils.spec        |  2 ++
 format-security.patch | 11 +++++++++++
 2 files changed, 13 insertions(+)
---
diff --git a/coreutils.spec b/coreutils.spec
index 0efe01b..3625930 100644
--- a/coreutils.spec
+++ b/coreutils.spec
@@ -29,6 +29,7 @@ Patch7:		%{name}-sparc64.patch
 Patch8:		%{name}-pl.po-update.patch
 # from http://www.beatex.org/web/advancedcopy.html, edited by shadzik
 Patch9:		%{name}-advcopy.patch
+Patch10:	format-security.patch
 URL:		http://www.gnu.org/software/coreutils/
 BuildRequires:	acl-devel
 BuildRequires:	attr-devel
@@ -116,6 +117,7 @@ Programy zawarte w tym pakiecie to:
 # progress-bar patch, -g,--progress-bar //if in doubt, comment it out
 %patch9 -p1
 %endif
+%patch10 -p1
 
 %{__perl} -pi -e 's at GNU/Linux at PLD Linux@' m4/host-os.m4
 
diff --git a/format-security.patch b/format-security.patch
new file mode 100644
index 0000000..676a203
--- /dev/null
+++ b/format-security.patch
@@ -0,0 +1,11 @@
+--- coreutils-8.20/gnulib-tests/test-xvasprintf.c~	2012-10-23 16:17:25.000000000 +0200
++++ coreutils-8.20/gnulib-tests/test-xvasprintf.c	2012-12-17 23:51:09.622359300 +0100
+@@ -95,7 +95,7 @@
+   {
+     /* Silence gcc warning about zero-length format string.  */
+     const char *empty = "";
+-    result = xasprintf (empty);
++    result = xasprintf ("%s",empty);
+     ASSERT (result != NULL);
+     ASSERT (strcmp (result, "") == 0);
+     free (result);
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/coreutils.git/commitdiff/5b496f544d816a66ae486da369837a1d1e7b75ef



More information about the pld-cvs-commit mailing list