From 6b618f3c17d09ac4b2d090f97c6aea761c832ef6 Mon Sep 17 00:00:00 2001 From: Tomas Bzatek Date: Feb 08 2012 16:18:41 +0000 Subject: Prevent deadlock when cancelling a watch (#786170) --- diff --git a/gamin-0.1.11-double-lock.patch b/gamin-0.1.11-double-lock.patch new file mode 100644 index 0000000..befb865 --- /dev/null +++ b/gamin-0.1.11-double-lock.patch @@ -0,0 +1,35 @@ +From 50df2c4de7b3aa8bed8781c92afb9a635a01df3f Mon Sep 17 00:00:00 2001 +From: Sandro Mani +Date: Fri, 3 Feb 2012 09:10:21 +0100 +Subject: [PATCH] Fix double lock + +https://bugzilla.gnome.org/show_bug.cgi?id=669292 +--- + server/inotify-helper.c | 4 ---- + 1 files changed, 0 insertions(+), 4 deletions(-) + +diff --git a/server/inotify-helper.c b/server/inotify-helper.c +index d77203e..defa7c6 100644 +--- a/server/inotify-helper.c ++++ b/server/inotify-helper.c +@@ -127,9 +127,6 @@ ih_sub_add (ih_sub_t * sub) + gboolean + ih_sub_cancel (ih_sub_t * sub) + { +- G_LOCK(inotify_lock); +- +- + if (!sub->cancelled) + { + IH_W("cancelling %s\n", sub->pathname); +@@ -140,7 +137,6 @@ ih_sub_cancel (ih_sub_t * sub) + sub_list = g_list_remove (sub_list, sub); + } + +- G_UNLOCK(inotify_lock); + return TRUE; + } + +-- +1.7.9 + diff --git a/gamin.spec b/gamin.spec index ea29c84..f74fc53 100644 --- a/gamin.spec +++ b/gamin.spec @@ -1,7 +1,7 @@ Summary: Library providing the FAM File Alteration Monitor API Name: gamin Version: 0.1.10 -Release: 11%{?dist} +Release: 12%{?dist} License: LGPLv2 #some of the files (server/inotify-kernel.c) are GPLv2 #so https://fedoraproject.org/wiki/Licensing#GPL_Compatibility_Matrix @@ -25,6 +25,9 @@ Patch1: gamin-0.1.10-gnueabi.patch # Don't try to build with -DG_DISABLE_DEPRECATED - glib has moved on Patch2: gamin-manape.patch +# gam_server deadlocks, leading to all KDE applications hanging at start +# https://bugzilla.redhat.com/show_bug.cgi?id=786170 +Patch3: gamin-0.1.11-double-lock.patch %description This C library provides an API and ABI compatible file alteration @@ -57,6 +60,7 @@ of the gamin package. %setup -q %patch1 -p1 -b .gnueabi %patch2 -p1 -b .manape +%patch3 -p1 -b .double-lock # recode docs into UTF-8 for i in ChangeLog NEWS ; do @@ -119,6 +123,9 @@ rm -fr %{buildroot} %doc doc/python.html %changelog +* Wed Feb 8 2012 Tomas Bzatek - 0.1.10-12 +- Prevent deadlock when cancelling a watch (#786170) + * Fri Jan 13 2012 Fedora Release Engineering - 0.1.10-11 - Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild