summaryrefslogtreecommitdiffstats
path: root/recipes-extended
diff options
context:
space:
mode:
authorPeter Kjellerstedt <peter.kjellerstedt@axis.com>2017-10-03 22:26:41 +0200
committerRoss Burton <ross.burton@intel.com>2017-10-04 15:33:42 +0100
commit08afd879388514af24e2c720066d479cfc71a433 (patch)
treee2d7e805f7e427d253af96a38d280210b1ffddee /recipes-extended
parent4bed302b143c4d869f83fcc34b0c1ad1dd143c2d (diff)
downloadmeta-gplv2-08afd879388514af24e2c720066d479cfc71a433.tar.gz
groff: Make it build with compile time hardening enabled
This avoids the following error: src/devices/grohtml/post-html.cc: In member function 'void header_desc::write_headings(FILE*, int)': src/devices/grohtml/post-html.cc:1402:32: error: format not a string literal and no format arguments [-Werror=format-security] fprintf(f, buffer.contents()); Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Diffstat (limited to 'recipes-extended')
-rw-r--r--recipes-extended/groff/groff-1.18.1.4/0001-Make-it-build-with-compile-time-hardening-enabled.patch35
-rw-r--r--recipes-extended/groff/groff_1.18.1.4.bb13
2 files changed, 42 insertions, 6 deletions
diff --git a/recipes-extended/groff/groff-1.18.1.4/0001-Make-it-build-with-compile-time-hardening-enabled.patch b/recipes-extended/groff/groff-1.18.1.4/0001-Make-it-build-with-compile-time-hardening-enabled.patch
new file mode 100644
index 0000000..43404fa
--- /dev/null
+++ b/recipes-extended/groff/groff-1.18.1.4/0001-Make-it-build-with-compile-time-hardening-enabled.patch
@@ -0,0 +1,35 @@
1From a1cd31daf05023a14d8e904a409cecbfc0fae93e Mon Sep 17 00:00:00 2001
2From: Peter Kjellerstedt <pkj@axis.com>
3Date: Mon, 2 Oct 2017 14:34:14 +0200
4Subject: [PATCH 1/2] Make it build with compile time hardening enabled
5
6This avoids the following error:
7
8 src/devices/grohtml/post-html.cc: In member function 'void
9 header_desc::write_headings(FILE*, int)':
10 src/devices/grohtml/post-html.cc:1402:32: error: format not a string
11 literal and no format arguments [-Werror=format-security]
12 fprintf(f, buffer.contents());
13
14Upstream-Status: Inappropriate [legacy version]
15Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
16---
17 src/devices/grohtml/post-html.cc | 2 +-
18 1 file changed, 1 insertion(+), 1 deletion(-)
19
20diff --git a/src/devices/grohtml/post-html.cc b/src/devices/grohtml/post-html.cc
21index 3c09d7c..1ad5580 100644
22--- a/src/devices/grohtml/post-html.cc
23+++ b/src/devices/grohtml/post-html.cc
24@@ -1399,7 +1399,7 @@ void header_desc::write_headings (FILE *f, int force)
25
26 buffer += as_string(h);
27 buffer += '\0';
28- fprintf(f, buffer.contents());
29+ fprintf(f, "%s", buffer.contents());
30 } else
31 fputs(g->text_string, f);
32 h++;
33--
342.12.0
35
diff --git a/recipes-extended/groff/groff_1.18.1.4.bb b/recipes-extended/groff/groff_1.18.1.4.bb
index fc7eb44..0d1520d 100644
--- a/recipes-extended/groff/groff_1.18.1.4.bb
+++ b/recipes-extended/groff/groff_1.18.1.4.bb
@@ -9,12 +9,13 @@ PR = "r1"
9LIC_FILES_CHKSUM = "file://COPYING;md5=e43fc16fccd8519fba405f0a0ff6e8a3" 9LIC_FILES_CHKSUM = "file://COPYING;md5=e43fc16fccd8519fba405f0a0ff6e8a3"
10 10
11SRC_URI = "${GNU_MIRROR}/${BPN}/old/${BP}.tar.gz \ 11SRC_URI = "${GNU_MIRROR}/${BPN}/old/${BP}.tar.gz \
12 file://groff-1.18.1.4-remove-mom.patch;striplevel=1 \ 12 file://groff-1.18.1.4-remove-mom.patch;striplevel=1 \
13 file://man-local.patch \ 13 file://man-local.patch \
14 file://mdoc-local.patch \ 14 file://mdoc-local.patch \
15 file://groff-1.18.1.4-fix-bindir.patch \ 15 file://groff-1.18.1.4-fix-bindir.patch \
16 file://fix-narrowing-conversion-error.patch \ 16 file://fix-narrowing-conversion-error.patch \
17" 17 file://0001-Make-it-build-with-compile-time-hardening-enabled.patch \
18"
18 19
19inherit autotools texinfo 20inherit autotools texinfo
20 21