[seahorse-plugins/f14/master] try to fix a crash-at-shutdown

Matthias Clasen mclasen at fedoraproject.org
Fri Sep 3 18:26:38 UTC 2010


commit 703d2ccee5b06021e4f6bacbf87d72988fc87906
Author: Matthias Clasen <mclasen at redhat.com>
Date:   Fri Sep 3 14:25:26 2010 -0400

    try to fix a crash-at-shutdown

 clipboard-disconnect.patch |   52 ++++++++++++++++++++++++++++++++++++++++++++
 seahorse-plugins.spec      |   19 +++++++++++-----
 2 files changed, 65 insertions(+), 6 deletions(-)
---
diff --git a/clipboard-disconnect.patch b/clipboard-disconnect.patch
new file mode 100644
index 0000000..2d6b9a0
--- /dev/null
+++ b/clipboard-disconnect.patch
@@ -0,0 +1,52 @@
+diff -up seahorse-plugins-2.30.1/plugins/applet/seahorse-applet.c.clipboard seahorse-plugins-2.30.1/plugins/applet/seahorse-applet.c
+--- seahorse-plugins-2.30.1/plugins/applet/seahorse-applet.c.clipboard	2010-09-03 14:12:07.671035002 -0400
++++ seahorse-plugins-2.30.1/plugins/applet/seahorse-applet.c	2010-09-03 14:19:06.757035002 -0400
+@@ -151,6 +151,9 @@ typedef struct _SeahorseAppletPrivate {
+     GtkClipboard        *board;
+     GtkWidget           *menu;
+     SeahorseTextType    clipboard_contents;
++
++    gulong clipboard_owner_change_id;
++    gulong primary_owner_change_id;
+ } SeahorseAppletPrivate;
+ 
+ #define SEAHORSE_APPLET_GET_PRIVATE(obj)  (G_TYPE_INSTANCE_GET_PRIVATE ((obj), SEAHORSE_TYPE_APPLET, SeahorseAppletPrivate))
+@@ -898,14 +901,15 @@ seahorse_applet_init (SeahorseApplet *ap
+     atom = gdk_atom_intern ("CLIPBOARD", FALSE);
+     board = gtk_clipboard_get (atom);
+     handle_clipboard_owner_change (board, NULL, applet);
+-    g_signal_connect (board, "owner-change",
+-                      G_CALLBACK (handle_clipboard_owner_change), applet);
++    priv->clipboard_owner_change_id =
++      g_signal_connect (board, "owner-change",
++                        G_CALLBACK (handle_clipboard_owner_change), applet);
+     
+     atom = gdk_atom_intern ("PRIMARY", FALSE);
+     board = gtk_clipboard_get (atom);
+-    g_signal_connect (board, "owner-change",
+-                      G_CALLBACK (handle_clipboard_owner_change), applet);
+-                      
++    priv->primary_owner_change_id =
++      g_signal_connect (board, "owner-change",
++                        G_CALLBACK (handle_clipboard_owner_change), applet);
+ }
+ 
+ static void
+@@ -944,6 +948,17 @@ static void
+ seahorse_applet_finalize (GObject *object)
+ {
+     SeahorseAppletPrivate *priv = SEAHORSE_APPLET_GET_PRIVATE (object);
++    GtkClipboard *board;
++
++    if (priv->clipboard_owner_change_id) {
++        g_signal_handler_disconnect (gdk_clipboard_get (GDK_SELECTION_CLIPBOARD),
++                                     priv->clipboard_owner_change_id);
++    }
++
++    if (priv->primary_owner_change_id) {
++        g_signal_handler_disconnect (gdk_clipboard_get (GDK_SELECTION_PRIMARY),
++                                     priv->primary_owner_change_id);
++    }
+ 
+     if (priv) {
+         if (priv->menu)
diff --git a/seahorse-plugins.spec b/seahorse-plugins.spec
index fa892b6..ab0076c 100644
--- a/seahorse-plugins.spec
+++ b/seahorse-plugins.spec
@@ -1,6 +1,6 @@
 Name:		seahorse-plugins
 Version:	2.30.1
-Release:	3%{?dist}
+Release:	4%{?dist}
 Summary:	Plugins and utilities for encryption in GNOME
 Group:		User Interface/Desktops
 License:	GPLv2+ and GFDL
@@ -11,6 +11,9 @@ Source1:	seahorse-agent.sh
 # https://bugzilla.gnome.org/show_bug.cgi?id=579738
 Patch0:		seahorse-agent-uninit.patch
 
+# https://bugzilla.gnome.org/show_bug.cgi?id=628720
+Patch1:         clipboard-disconnect.patch
+
 BuildRequires:  intltool
 BuildRequires:  gettext-devel
 BuildRequires:  gnome-doc-utils
@@ -144,7 +147,7 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor >&/dev/null || :
 %doc AUTHORS COPYING NEWS README
 %{_sysconfdir}/X11/xinit/xinitrc.d/seahorse-agent.sh
 %{_sysconfdir}/gconf/schemas/seahorse-plugins.schemas
-# %{_sysconfdir}/gconf/schemas/seahorse-gedit.schemas
+%{_sysconfdir}/gconf/schemas/seahorse-gedit.schemas
 %{_bindir}/seahorse-agent
 %{_bindir}/seahorse-preferences
 %{_bindir}/seahorse-tool
@@ -165,10 +168,10 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor >&/dev/null || :
 %{_datadir}/icons/hicolor/scalable/apps/seahorse-applet.svg
 
 # gedit plugin
-# %dir %{_libdir}/gedit-2
-# %dir %{_libdir}/gedit-2/plugins
-# %{_libdir}/gedit-2/plugins/libseahorse-pgp.so
-# %{_libdir}/gedit-2/plugins/seahorse-pgp.gedit-plugin
+%dir %{_libdir}/gedit-2
+%dir %{_libdir}/gedit-2/plugins
+%{_libdir}/gedit-2/plugins/libseahorse-pgp.so
+%{_libdir}/gedit-2/plugins/seahorse-pgp.gedit-plugin
 
 # nautilus extension
 %dir %{_libdir}/nautilus/extensions-2.0
@@ -182,6 +185,10 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor >&/dev/null || :
 #%{_libdir}/epiphany/2.27/extensions/seahorse.ephy-extension
 
 %changelog
+* Fri Sep  3 2010 Matthias Clasen <mclasen at redhat.com> 2.30.1-4
+- Try to fix a crash-at-shutdown (#601215)
+- Bring back the gedit plugin
+
 * Wed Aug 11 2010 Matthias Clasen <mclasen at redhat.com> 2.30.1-3
 - Rebuild against newer nautilus
 


More information about the scm-commits mailing list