Fix for psplash segmentation fault
PATCH 1/1 Fix for psplash segmentation fault
Fix segmentation fault when passing -a without angel value.
When psplash -a is called instead of psplash -a<angle value> it will segmentation fault calling out of bound argv[].
git://git.yoctoproject.org/psplash
-----------------------------------------------------------------
psplash.c +1 -1
@@ -219,7 +219,7 @@ main (int argc, char** argv)if (!strcmp (argv[i],"-a" ) || !strcmp (argv[i],"--angle" )) { -if (++i > argc) goto fail; +if (++i >= argc) goto fail; angle =atoi (argv[i]);continue ; }
s/angel/angle :)
Aws\
Quoted 29 lines · Aws Ismail
Fix segmentation fault when passing -a without angel value.
When psplash -a is called instead of psplash -a<angle value> it will segmentation fault calling out of bound argv[].
git://git.yoctoproject.org/psplashSigned-of-by Aws Ismail<[email protected]>-----------------------------------------------------------------
psplash.c +1
-1@@ -219,7 +219,7 @@ main (int argc, char** argv)if (!strcmp (argv[i],"-a" ) || !strcmp (argv[i],"--angle" )) { -if (++i > argc) goto fail; +if (++i >= argc) goto fail; angle =atoi (argv[i]);continue ; }_______________________________________________
yocto mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/yocto
Signature · 3 lines
----------- Aws Ismail -----------
Hi all,
This is a follow-up on the fix I sent recently for psplash. I'd appreciate any comments.
Thanks
Aws Ismail
====================================================================
Fix psplash segmentation fault
This fixes the segmentation fault when calling:
psplash -a
The -a option requires a rotation angle to be given and if it is missing then the user is shown the correct usage.
From: git://git.yoctoproject.org/psplash
--------------------------------------------------------------------
psplash.c +1 -1
@@ -219,7 +219,7 @@ main (int argc, char** argv)if (!strcmp (argv[i],"-a" ) || !strcmp (argv[i],"--angle" )) { -if (++i > argc) goto fail; +if (++i >= argc) goto fail; angle =atoi (argv[i]);continue ; }
Quoted 29 lines · Aws Ismail
Fix segmentation fault when passing -a without angle value.
When psplash -a is called instead of psplash -a<angle value> it will segmentation fault calling out of bound argv[].
git://git.yoctoproject.org/psplashSigned-of-by Aws Ismail<[email protected]>-----------------------------------------------------------------
psplash.c +1
-1@@ -219,7 +219,7 @@ main (int argc, char** argv)if (!strcmp (argv[i],"-a" ) || !strcmp (argv[i],"--angle" )) { -if (++i > argc) goto fail; +if (++i >= argc) goto fail; angle =atoi (argv[i]);continue ; }_______________________________________________
yocto mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/yocto
Saul Wold
AppliedQuoted 17 lines · Aws Ismail
Fix segmentation fault when passing -a without angel value.
When psplash -a is called instead of psplash -a<angle value> it will segmentation fault calling out of bound argv[].
git://git.yoctoproject.org/psplashSigned-of-by Aws Ismail<[email protected]>-----------------------------------------------------------------
psplash.c +0
-0
psplash.c main (int argc, char** argv) · line 225
Quoted 8 lines
psplash.c +1
-1@@ -219,7 +219,7 @@ main (int argc, char** argv)if (!strcmp (argv[i],"-a" ) || !strcmp (argv[i],"--angle" )) { -if (++i > argc) goto fail; +if (++i >= argc) goto fail; angle =atoi (argv[i]);continue ; }
Merged into psplash upstream, if you would like to send a patch to Openembedded-Core updating the psplash recipe that would be welcome also.
Thanks
Sau!
Quoted 6 lines
_______________________________________________
yocto mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/yocto