]> git.pld-linux.org Git - packages/cvs.git/commitdiff
Fix build with -Werror=format-security
authorMarcin Banasiak <marcin.banasiak@gmail.com>
Tue, 5 Feb 2013 20:59:41 +0000 (21:59 +0100)
committerMarcin Banasiak <marcin.banasiak@gmail.com>
Tue, 5 Feb 2013 20:59:41 +0000 (21:59 +0100)
cvs-format-security.patch [new file with mode: 0644]
cvs.spec

diff --git a/cvs-format-security.patch b/cvs-format-security.patch
new file mode 100644 (file)
index 0000000..106cc96
--- /dev/null
@@ -0,0 +1,24 @@
+diff -urN cvs-1.12.13/diff/diff3.c cvs-1.12.13.new/diff/diff3.c
+--- cvs-1.12.13/diff/diff3.c   2004-10-09 17:51:52.000000000 +0200
++++ cvs-1.12.13.new/diff/diff3.c       2013-02-05 21:38:47.024405045 +0100
+@@ -1503,7 +1503,7 @@
+             line = 0;
+             do
+               {
+-                printf_output (line_prefix);
++                printf_output ("%s", line_prefix);
+                 cp = D_RELNUM (ptr, realfile, line);
+                 length = D_RELLEN (ptr, realfile, line);
+                 write_output (cp, length);
+diff -urN cvs-1.12.13/src/main.c cvs-1.12.13.new/src/main.c
+--- cvs-1.12.13/src/main.c     2013-02-05 21:33:06.000000000 +0100
++++ cvs-1.12.13.new/src/main.c 2013-02-05 21:43:02.996351658 +0100
+@@ -1475,7 +1475,7 @@
+ {
+     (void) fprintf (stderr, *cpp++, program_name, cvs_cmd_name);
+     for (; *cpp; cpp++)
+-      (void) fprintf (stderr, *cpp);
++      (void) fputs (*cpp, stderr);
+     exit (EXIT_FAILURE);
+ }
index ff6c2169c8a521eadd69716430202f40608dd340..46200bae5c05025c0e4b158940c42e28bd3e8071 100644 (file)
--- a/cvs.spec
+++ b/cvs.spec
@@ -32,6 +32,7 @@ Patch9:               %{name}-getcwd.patch
 Patch10:       %{name}-ac.patch
 Patch11:       %{name}-printf-n.patch
 Patch12:       %{name}-am.patch
+Patch13:       %{name}-format-security.patch
 
 # patches from debian
 Patch100:      %{name}-debian-64bit-crash.patch
@@ -241,6 +242,7 @@ pserver.
 %patch10 -p1
 %patch11 -p1
 %patch12 -p1
+%patch13 -p1
 
 %patch100 -p1
 %patch101 -p1
This page took 0.073569 seconds and 4 git commands to generate.