From 41e542d2c81f84e11722ae8376ccec2694224ca235bea27b0db62b4a554e1a35 Mon Sep 17 00:00:00 2001 From: OBS User unknown Date: Wed, 21 May 2008 22:27:47 +0000 Subject: [PATCH] OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/gvfs?expand=0&rev=17 --- gvfs-bgo531516-fuse-cleanup-when-killed.patch | 35 +++++++++++++++++++ gvfs.changes | 6 ++++ gvfs.spec | 8 ++++- 3 files changed, 48 insertions(+), 1 deletion(-) create mode 100644 gvfs-bgo531516-fuse-cleanup-when-killed.patch diff --git a/gvfs-bgo531516-fuse-cleanup-when-killed.patch b/gvfs-bgo531516-fuse-cleanup-when-killed.patch new file mode 100644 index 0000000..d0fedf0 --- /dev/null +++ b/gvfs-bgo531516-fuse-cleanup-when-killed.patch @@ -0,0 +1,35 @@ +Index: client/gvfsfusedaemon.c +=================================================================== +--- client/gvfsfusedaemon.c (revision 1774) ++++ client/gvfsfusedaemon.c (working copy) +@@ -2049,6 +2049,18 @@ dbus_filter_func (DBusConnection *connec + return DBUS_HANDLER_RESULT_NOT_YET_HANDLED; + } + ++static gboolean ++shutdown_on_idle (void) ++{ ++ fuse_exit (fuse_get_context ()->fuse); ++ return FALSE; ++} ++ ++static void ++shutdown_signal (gint signum) ++{ ++ g_idle_add ((GSourceFunc) shutdown_on_idle, NULL); ++} + + static gpointer + vfs_init (struct fuse_conn_info *conn) +@@ -2102,6 +2114,11 @@ vfs_init (struct fuse_conn_info *conn) + volume_monitor = g_object_new (g_type_from_name ("GDaemonVolumeMonitor"), NULL); + + subthread_main_loop = g_main_loop_new (NULL, FALSE); ++ ++ signal (SIGHUP, shutdown_signal); ++ signal (SIGTERM, shutdown_signal); ++ signal (SIGINT, shutdown_signal); ++ + subthread = g_thread_create ((GThreadFunc) subthread_main, NULL, FALSE, NULL); + + return NULL; diff --git a/gvfs.changes b/gvfs.changes index 0bf801f..42a2048 100644 --- a/gvfs.changes +++ b/gvfs.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Thu May 22 00:05:26 CEST 2008 - hpj@suse.de + +- Add gvfs-bgo531516-fuse-cleanup-when-killed.patch, which fixes + the remaining issues covered by BNC #368628. + ------------------------------------------------------------------- Tue May 13 07:38:54 CEST 2008 - hpj@suse.de diff --git a/gvfs.spec b/gvfs.spec index 83c4e7a..616242f 100644 --- a/gvfs.spec +++ b/gvfs.spec @@ -25,7 +25,7 @@ BuildRequires: extra-rpm-macros %endif Summary: VFS functionality for GLib Version: 0.2.3 -Release: 19 +Release: 23 License: LGPL v2.0 or later Group: Development/Libraries/C and C++ Source0: %{name}-%{version}.tar.bz2 @@ -35,6 +35,8 @@ Patch0: gvfs-no-shebang.patch Patch1: gvfs-bnc368628-fuse-robustness.patch # PATCH-FIX-UPSTREAM gvfs-bnc382172-home-trash-monitoring.patch hpj@novell.com Patch2: gvfs-bnc382172-home-trash-monitoring.patch +# PATCH-FIX-UPSTREAM gvfs-bgo531516-fuse-cleanup-when-killed.patch bgo531516 bnc368628 hpj@novell.com +Patch3: gvfs-bgo531516-fuse-cleanup-when-killed.patch Url: http://www.gnome.org BuildRoot: %{_tmppath}/%{name}-%{version}-build AutoReqProv: on @@ -123,6 +125,7 @@ Authors: %patch0 -p1 %patch1 -p1 %patch2 -p1 +%patch3 -p0 %build export CFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing" @@ -177,6 +180,9 @@ chmod -x $RPM_BUILD_ROOT/%{_sysconfdir}/profile.d/* %files lang -f %{name}.lang %changelog +* Thu May 22 2008 hpj@suse.de +- Add gvfs-bgo531516-fuse-cleanup-when-killed.patch, which fixes + the remaining issues covered by BNC #368628. * Tue May 13 2008 hpj@suse.de - Add gvfs-bnc382172-home-trash-monitoring.patch, which fixes BNC #382172.