Package: papyrus / 3.7.1+dfsg-3

hardening.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
Description: Fix issues with gcc hardening compilations flags
Author: Mathieu Malaterre <malat@debian.org>
Forwarded: no

Index: Papyrus3/PapyError3.c
===================================================================
--- Papyrus3.orig/PapyError3.c	2013-10-28 16:57:00.000000000 +0100
+++ Papyrus3/PapyError3.c	2013-10-28 16:57:13.000000000 +0100
@@ -168,7 +168,7 @@
 #ifndef DLL
     PapyShort	i, theMax, theNb = 0;
 
-    fprintf (stderr, sPapyErrorDecoP);
+    fprintf (stderr, "%s", sPapyErrorDecoP);
     if (sCrtErrLevel >= 0)
     {
 	fprintf (stderr, "%s\n", sERRMSG);
@@ -202,7 +202,7 @@
     else
 	fprintf (stderr, "No e%s\n", &sERRMSG [1]);
 	
-    fprintf (stderr, sPapyErrorDecoP);
+    fprintf (stderr, "%s", sPapyErrorDecoP);
 #endif
     
 } /* endof PapyPrintErrMsg3 */
Index: Papyrus3/TESTS/TestRead.c
===================================================================
--- Papyrus3.orig/TESTS/TestRead.c	2013-10-28 16:57:00.000000000 +0100
+++ Papyrus3/TESTS/TestRead.c	2013-10-28 16:57:13.000000000 +0100
@@ -53,6 +53,7 @@
 #define MAIN
 
 #include <stdio.h>
+#include <stdlib.h> /* exit */
 #include "Papyrus3.h"