[epiphany] ephy-embed-shell: set bus watch id to zero



commit e0e7b8004b874294d887c99b2421bd3a1e618b38
Author: Xan Lopez <xan igalia com>
Date:   Tue Mar 12 20:49:35 2013 +0100

    ephy-embed-shell: set bus watch id to zero
    
    Since dispose can run multiple times.
    
    Patch by Carlos GarcĂ­a Campos <cgarcia igalia com>

 embed/ephy-embed-shell.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/embed/ephy-embed-shell.c b/embed/ephy-embed-shell.c
index 19e5432..42ba8ed 100644
--- a/embed/ephy-embed-shell.c
+++ b/embed/ephy-embed-shell.c
@@ -106,8 +106,10 @@ ephy_embed_shell_dispose (GObject *object)
   g_clear_object (&priv->embed_single);
 #ifdef HAVE_WEBKIT2
   g_clear_object (&priv->web_extension);
-  if (priv->web_extension_watch_name_id > 0)
+  if (priv->web_extension_watch_name_id > 0) {
     g_bus_unwatch_name (priv->web_extension_watch_name_id);
+    priv->web_extension_watch_name_id = 0;
+  }
 #else
   g_clear_object (&priv->adblock_manager);
 #endif


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]