summaryrefslogtreecommitdiffstats
path: root/meta-multimedia
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2017-06-26 22:57:08 -0700
committerMartin Jansa <Martin.Jansa@gmail.com>2017-07-01 09:59:26 +0200
commitd193035a51c0b10cdfe72e728541ab7ca447e995 (patch)
tree7a44e7bea62e1c4e97584d7a2f85ef90096daefc /meta-multimedia
parent6fb9a9e7a2288d8cef253beb6c5ad0a7e5daa669 (diff)
downloadmeta-openembedded-d193035a51c0b10cdfe72e728541ab7ca447e995.tar.gz
cdparanoia: Fix build with security flags
Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Diffstat (limited to 'meta-multimedia')
-rw-r--r--meta-multimedia/recipes-multimedia/cdparanoia/cdparanoia_10.2.bb4
-rw-r--r--meta-multimedia/recipes-multimedia/cdparanoia/files/0001-check-for-null-buffer-before-trying-a-byteswap.patch31
-rw-r--r--meta-multimedia/recipes-multimedia/cdparanoia/files/0002-Fix-printf-format-errors.patch32
3 files changed, 66 insertions, 1 deletions
diff --git a/meta-multimedia/recipes-multimedia/cdparanoia/cdparanoia_10.2.bb b/meta-multimedia/recipes-multimedia/cdparanoia/cdparanoia_10.2.bb
index e846e3a97..30d71ff2c 100644
--- a/meta-multimedia/recipes-multimedia/cdparanoia/cdparanoia_10.2.bb
+++ b/meta-multimedia/recipes-multimedia/cdparanoia/cdparanoia_10.2.bb
@@ -13,7 +13,9 @@ SRC_URI = "http://downloads.xiph.org/releases/cdparanoia/cdparanoia-III-${PV}.sr
13 file://0003-Fix-missing-shared-object-LDFLAGS.patch \ 13 file://0003-Fix-missing-shared-object-LDFLAGS.patch \
14 file://dont-use-internal-configs.patch \ 14 file://dont-use-internal-configs.patch \
15 file://out-of-tree-build.patch \ 15 file://out-of-tree-build.patch \
16" 16 file://0001-check-for-null-buffer-before-trying-a-byteswap.patch \
17 file://0002-Fix-printf-format-errors.patch \
18 "
17SRC_URI[md5sum] = "b304bbe8ab63373924a744eac9ebc652" 19SRC_URI[md5sum] = "b304bbe8ab63373924a744eac9ebc652"
18SRC_URI[sha256sum] = "005db45ef4ee017f5c32ec124f913a0546e77014266c6a1c50df902a55fe64df" 20SRC_URI[sha256sum] = "005db45ef4ee017f5c32ec124f913a0546e77014266c6a1c50df902a55fe64df"
19 21
diff --git a/meta-multimedia/recipes-multimedia/cdparanoia/files/0001-check-for-null-buffer-before-trying-a-byteswap.patch b/meta-multimedia/recipes-multimedia/cdparanoia/files/0001-check-for-null-buffer-before-trying-a-byteswap.patch
new file mode 100644
index 000000000..682cf6e03
--- /dev/null
+++ b/meta-multimedia/recipes-multimedia/cdparanoia/files/0001-check-for-null-buffer-before-trying-a-byteswap.patch
@@ -0,0 +1,31 @@
1From c760c5d31f2412a5be5ac6896e6069d1cea08527 Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Mon, 26 Jun 2017 22:31:45 -0700
4Subject: [PATCH 1/2] check for null buffer before trying a byteswap
5
6Author: Monty <paranoia@xiph.org>
7
8Patch from debian
9http://sources.debian.net/src/cdparanoia/3.10.2%2Bdebian-11/debian/patches/04-endian.patch
10
11Signed-off-by: Khem Raj <raj.khem@gmail.com>
12---
13 interface/interface.c | 2 +-
14 1 file changed, 1 insertion(+), 1 deletion(-)
15
16diff --git a/interface/interface.c b/interface/interface.c
17index 526c2a9..763a0ea 100644
18--- a/interface/interface.c
19+++ b/interface/interface.c
20@@ -118,7 +118,7 @@ long cdda_read_timed(cdrom_drive *d, void *buffer, long beginsector, long sector
21 if(d->bigendianp==-1) /* not determined yet */
22 d->bigendianp=data_bigendianp(d);
23
24- if(d->bigendianp!=bigendianp()){
25+ if(buffer && d->bigendianp!=bigendianp()){
26 int i;
27 u_int16_t *p=(u_int16_t *)buffer;
28 long els=sectors*CD_FRAMESIZE_RAW/2;
29--
302.13.2
31
diff --git a/meta-multimedia/recipes-multimedia/cdparanoia/files/0002-Fix-printf-format-errors.patch b/meta-multimedia/recipes-multimedia/cdparanoia/files/0002-Fix-printf-format-errors.patch
new file mode 100644
index 000000000..024479ca7
--- /dev/null
+++ b/meta-multimedia/recipes-multimedia/cdparanoia/files/0002-Fix-printf-format-errors.patch
@@ -0,0 +1,32 @@
1From f4f81bdadb9515938b3b5d13707bd4b9322fd967 Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Mon, 26 Jun 2017 22:37:13 -0700
4Subject: [PATCH 2/2] Fix printf format errors
5
6error: format not a string literal and no format arguments
7
8Signed-off-by: Khem Raj <raj.khem@gmail.com>
9---
10 main.c | 4 ++--
11 1 file changed, 2 insertions(+), 2 deletions(-)
12
13diff --git a/main.c b/main.c
14index 664acac..d568fb1 100644
15--- a/main.c
16+++ b/main.c
17@@ -588,10 +588,10 @@ static void callback(long inpos, int function){
18 buffer[aheadposition+19]='>';
19 }
20
21- fprintf(stderr,buffer);
22+ fprintf(stderr, "%s", buffer);
23
24 if (logfile != NULL && function==-1) {
25- fprintf(logfile,buffer+1);
26+ fprintf(logfile, "%s", buffer+1);
27 fprintf(logfile,"\n\n");
28 fflush(logfile);
29 }
30--
312.13.2
32