File: 08_hardening.patch

package info (click to toggle)
jigzo 0.6.1-8
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 5,228 kB
  • sloc: cpp: 1,745; makefile: 114
file content (36 lines) | stat: -rw-r--r-- 1,019 bytes parent folder | download | duplicates (3)
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
Description: Improving hardening
 Adding extra FLAGS to Makefile and fixing a hardening error
 with fprintf

Forwarded: not-needed
Author: Elías Alejandro Año Mendoza <ealmdz@gmail.com>
Last-Update: 2016-07-14

--- jigzo-0.6.1.orig/Makefile
+++ jigzo-0.6.1/Makefile
@@ -31,6 +31,12 @@ ifeq "$(ARCH_OK)" "yes"
 CXXFLAGS = -g $(ARCHCXXFLAGS) -DENABLE_SOUND
 LDFLAGS = -O2 $(ARCHLDFLAGS)
 
+CPPFLAGS:=$(shell dpkg-buildflags --get CPPFLAGS) $(CXXFLAGS)
+CFLAGS:=$(shell dpkg-buildflags --get CFLAGS) $(CPPFLAGS)
+CXXFLAGS:=$(shell dpkg-buildflags --get CXXFLAGS) $(CPPFLAGS)
+LDFLAGS:=$(shell dpkg-buildflags --get LDFLAGS) $(LDFLAGS)
+
+
 #
 # List of all source files.
 #
Index: jigzo-0.6.1/src/main.cxx
===================================================================
--- jigzo-0.6.1.orig/src/main.cxx
+++ jigzo-0.6.1/src/main.cxx
@@ -1653,7 +1653,7 @@ int main(int argc, char **argv)
 		s.Exit();
 
 	} catch (LoaderException& e) {
-		fprintf(stderr,e.what());
+		fprintf(stderr,"%s",e.what());
 	}
 
 	return 0;