From 2d5fa9a848374cb5580b061cdb288b9898f867ce Mon Sep 17 00:00:00 2001 From: Ray Strode Date: Nov 15 2008 03:11:53 +0000 Subject: - Allow NULL to ply_image_free --- diff --git a/plymouth-0.6.0-dont-crash-on-null-free.patch b/plymouth-0.6.0-dont-crash-on-null-free.patch new file mode 100644 index 0000000..a204936 --- /dev/null +++ b/plymouth-0.6.0-dont-crash-on-null-free.patch @@ -0,0 +1,14 @@ +diff -up plymouth-0.6.0/src/libplybootsplash/ply-image.c.dont-crash-on-null-free plymouth-0.6.0/src/libplybootsplash/ply-image.c +--- plymouth-0.6.0/src/libplybootsplash/ply-image.c.dont-crash-on-null-free 2008-11-14 22:09:39.000000000 -0500 ++++ plymouth-0.6.0/src/libplybootsplash/ply-image.c 2008-11-14 22:09:58.000000000 -0500 +@@ -115,7 +115,9 @@ ply_image_new (const char *filename) + void + ply_image_free (ply_image_t *image) + { +- assert (image != NULL); ++ if (image == NULL) ++ return; ++ + assert (image->filename != NULL); + + if (image->layout.address != NULL) diff --git a/plymouth.spec b/plymouth.spec index 26dc02b..733c800 100644 --- a/plymouth.spec +++ b/plymouth.spec @@ -20,6 +20,8 @@ Requires: initscripts >= 8.83-1 Obsoletes: plymouth-text-and-details-only < %{version}-%{release} +Patch0: plymouth-0.6.0-dont-crash-on-null-free.patch + %description Plymouth provides an attractive graphical boot animation in place of the text messages that normally get shown. Text @@ -149,6 +151,7 @@ Plymouth. It features a blue flamed sun with animated solar flares. %prep %setup -q +%patch0 -p1 -b .dont-crash-on-null-free %build %configure --enable-tracing --disable-tests --without-boot-entry \ @@ -306,6 +309,9 @@ fi %defattr(-, root, root) %changelog +* Fri Nov 14 2008 Ray Strode 0.6.0-0.2008.11.14.3 +- Allow NULL to ply_image_free + * Fri Nov 14 2008 Ray Strode 0.6.0-0.2008.11.14.2 - Don't loop forever when tty returns NUL byte (bug 471498)