[oe-commits] Scott Garman : psplash: new patch to fix segfault
git at git.openembedded.org
git at git.openembedded.org
Thu Jan 3 12:33:57 UTC 2013
Module: openembedded-core.git
Branch: denzil
Commit: f5b8ba5e51ac41cf375119a88083617f667a85d5
URL: http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=f5b8ba5e51ac41cf375119a88083617f667a85d5
Author: Scott Garman <scott.a.garman at intel.com>
Date: Sat Dec 22 21:52:27 2012 -0800
psplash: new patch to fix segfault
This fixes a segmentation fault when passing -a without
an argument.
Fixes [YOCTO #2903]
Signed-off-by: Scott Garman <scott.a.garman at intel.com>
---
.../files/psplash_fix_bad_arg_segfault.patch | 22 ++++++++++++++++++++
meta/recipes-core/psplash/psplash_git.bb | 3 +-
2 files changed, 24 insertions(+), 1 deletions(-)
diff --git a/meta/recipes-core/psplash/files/psplash_fix_bad_arg_segfault.patch b/meta/recipes-core/psplash/files/psplash_fix_bad_arg_segfault.patch
new file mode 100644
index 0000000..f69c8a2
--- /dev/null
+++ b/meta/recipes-core/psplash/files/psplash_fix_bad_arg_segfault.patch
@@ -0,0 +1,22 @@
+Fix segmentation fault when passing -a without angle value.
+
+When psplash -a is called instead of psplash -a<angle value>, it will
+cause a segmentation fault by calling an out of bound argv[].
+
+Upstream-Status: Accepted
+Needed for denzil since we're not upgrading the recipe.
+
+Signed-off-by: Scott Garman <scott.a.garman at intel.com>
+
+diff -urN git.orig/psplash.c git/psplash.c
+--- git.orig/psplash.c 2012-12-22 21:28:05.830631789 -0800
++++ git/psplash.c 2012-12-22 21:29:54.962633330 -0800
+@@ -219,7 +219,7 @@
+
+ if (!strcmp(argv[i],"-a") || !strcmp(argv[i],"--angle"))
+ {
+- if (++i > argc) goto fail;
++ if (++i >= argc) goto fail;
+ angle = atoi(argv[i]);
+ continue;
+ }
diff --git a/meta/recipes-core/psplash/psplash_git.bb b/meta/recipes-core/psplash/psplash_git.bb
index f93afea..56a953b 100644
--- a/meta/recipes-core/psplash/psplash_git.bb
+++ b/meta/recipes-core/psplash/psplash_git.bb
@@ -7,10 +7,11 @@ LIC_FILES_CHKSUM = "file://psplash.h;beginline=1;endline=16;md5=840fb2356b10a85b
SRCREV = "e05374aae945bcfc6d962ed0d7b2774b77987e1d"
PV = "0.1+git${SRCPV}"
-PR = "r2"
+PR = "r3"
SRC_URI = "git://git.yoctoproject.org/${BPN};protocol=git \
file://psplash-init \
+ file://psplash_fix_bad_arg_segfault.patch \
${SPLASH_IMAGES}"
SPLASH_IMAGES = "file://psplash-poky-img.h;outsuffix=default"
More information about the Openembedded-commits
mailing list