[epiphany/gnome-3-18] web-view: properly remove password info bar weak pointer



commit c259d4924fcee951100c7e82e6041a07f5e8a2f7
Author: Michael Catanzaro <mcatanzaro gnome org>
Date:   Sun Aug 7 21:24:17 2016 -0500

    web-view: properly remove password info bar weak pointer

 embed/ephy-web-view.c |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/embed/ephy-web-view.c b/embed/ephy-web-view.c
index 1ad9600..ba07fbd 100644
--- a/embed/ephy-web-view.c
+++ b/embed/ephy-web-view.c
@@ -516,10 +516,13 @@ ephy_web_view_create_form_auth_save_confirmation_info_bar (EphyWebView *web_view
   ephy_embed_add_top_widget (EPHY_GET_EMBED_FROM_EPHY_WEB_VIEW (web_view),
                              info_bar, FALSE);
 
-  /* We track the info_bar, so we only ever show one */
-  if (web_view->priv->password_info_bar)
+  if (web_view->priv->password_info_bar) {
+    g_object_remove_weak_pointer (G_OBJECT (web_view->priv->password_info_bar),
+                                  (gpointer *)&web_view->priv->password_info_bar);
     gtk_widget_destroy (web_view->priv->password_info_bar);
+  }
 
+  /* We track the info_bar, so we only ever show one */
   web_view->priv->password_info_bar = info_bar;
   g_object_add_weak_pointer (G_OBJECT (info_bar),
                              (gpointer *)&web_view->priv->password_info_bar);


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