summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Januszewski <spock@gentoo.org>2006-07-15 21:47:53 +0000
committerMichael Januszewski <spock@gentoo.org>2006-07-15 21:47:53 +0000
commitd60ac377ce9de3b1a858bb9c1a3b3f41d640f4f8 (patch)
tree9683ea139fcd8e53bfe89c2c4dd44865df7c2597
parentshould be ~x86 only even though ebuild is copied from sendmail (diff)
downloadgentoo-2-d60ac377ce9de3b1a858bb9c1a3b3f41d640f4f8.tar.gz
gentoo-2-d60ac377ce9de3b1a858bb9c1a3b3f41d640f4f8.tar.bz2
gentoo-2-d60ac377ce9de3b1a858bb9c1a3b3f41d640f4f8.zip
Added a patch fixing a potential problem with the animation thread.
(Portage version: 2.1.1_pre2-r8)
-rw-r--r--media-gfx/splashutils/ChangeLog6
-rw-r--r--media-gfx/splashutils/files/splashutils-1.3-pthreads.patch48
-rw-r--r--media-gfx/splashutils/splashutils-1.3-r1.ebuild3
3 files changed, 55 insertions, 2 deletions
diff --git a/media-gfx/splashutils/ChangeLog b/media-gfx/splashutils/ChangeLog
index 4c00d681d585..08cb373e8a9c 100644
--- a/media-gfx/splashutils/ChangeLog
+++ b/media-gfx/splashutils/ChangeLog
@@ -1,6 +1,10 @@
# ChangeLog for media-gfx/splashutils
# Copyright 1999-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-gfx/splashutils/ChangeLog,v 1.60 2006/07/15 13:01:02 spock Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-gfx/splashutils/ChangeLog,v 1.61 2006/07/15 21:47:53 spock Exp $
+
+ 15 Jul 2006; Michał Januszewski <spock@gentoo.org>
+ +files/splashutils-1.3-pthreads.patch, splashutils-1.3-r1.ebuild:
+ Added a patch fixing a potential problem with the animation thread.
15 Jul 2006; Michał Januszewski <spock@gentoo.org>
+files/splashutils-1.3-fdset.patch, splashutils-1.3-r1.ebuild:
diff --git a/media-gfx/splashutils/files/splashutils-1.3-pthreads.patch b/media-gfx/splashutils/files/splashutils-1.3-pthreads.patch
new file mode 100644
index 000000000000..340b81a9357b
--- /dev/null
+++ b/media-gfx/splashutils/files/splashutils-1.3-pthreads.patch
@@ -0,0 +1,48 @@
+diff --git a/core/daemon.c b/core/daemon.c
+index 5f3f7db..0cf2e23 100644
+--- a/core/daemon.c
++++ b/core/daemon.c
+@@ -98,9 +98,10 @@ void *thf_anim(void *unused)
+ anim *a = NULL, *ca;
+ item *i;
+ mng_anim *mng;
+- int delay = 10000;
++ int delay = 10000, oldstate;
+
+ /* Render the first frame of all animations on the screen. */
++ pthread_setcancelstate(PTHREAD_CANCEL_DISABLE, &oldstate);
+ pthread_mutex_lock(&mtx_paint);
+ for (i = anims.head; i != NULL; i = i->next) {
+ ca = i->p;
+@@ -113,9 +114,10 @@ void *thf_anim(void *unused)
+ anim_render_frame(ca);
+ }
+ pthread_mutex_unlock(&mtx_paint);
++ pthread_setcancelstate(oldstate, NULL);
+
+ while(1) {
+-
++ pthread_setcancelstate(PTHREAD_CANCEL_DISABLE, &oldstate);
+ pthread_mutex_lock(&mtx_paint);
+ /* Find the shortest delay. */
+ for (i = anims.head; i != NULL; i = i->next) {
+@@ -133,9 +135,11 @@ void *thf_anim(void *unused)
+ }
+ }
+ pthread_mutex_unlock(&mtx_paint);
++ pthread_setcancelstate(oldstate, NULL);
+
+ usleep(delay * 1000);
+
++ pthread_setcancelstate(PTHREAD_CANCEL_DISABLE, &oldstate);
+ pthread_mutex_lock(&mtx_paint);
+ /* Don't paint anything if we aren't in silent mode. */
+ if (ctty != CTTY_SILENT)
+@@ -161,6 +165,7 @@ void *thf_anim(void *unused)
+ }
+
+ next: pthread_mutex_unlock(&mtx_paint);
++ pthread_setcancelstate(oldstate, NULL);
+
+ a = NULL;
+ delay = 10000;
diff --git a/media-gfx/splashutils/splashutils-1.3-r1.ebuild b/media-gfx/splashutils/splashutils-1.3-r1.ebuild
index 902ca0660cad..e9fcba42c85b 100644
--- a/media-gfx/splashutils/splashutils-1.3-r1.ebuild
+++ b/media-gfx/splashutils/splashutils-1.3-r1.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/media-gfx/splashutils/splashutils-1.3-r1.ebuild,v 1.2 2006/07/15 13:01:02 spock Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-gfx/splashutils/splashutils-1.3-r1.ebuild,v 1.3 2006/07/15 21:47:53 spock Exp $
inherit eutils multilib toolchain-funcs
@@ -65,6 +65,7 @@ src_unpack() {
cd ${S}
epatch ${FILESDIR}/splashutils-1.3-fdset.patch
+ epatch ${FILESDIR}/splashutils-1.3-pthreads.patch
# Check whether the kernel tree has been patched with fbsplash.
if [[ ! -e ${ROOT}/usr/lib/klibc/include/linux/console_splash.h ]]; then