[gnome-control-center/gnome-3-14] network: Fix warning on panel exit
- From: Bastien Nocera <hadess src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-control-center/gnome-3-14] network: Fix warning on panel exit
- Date: Thu, 19 Mar 2015 15:41:30 +0000 (UTC)
commit ff7c6233c9da9e49148ece07bf03bcc72e73a3b3
Author: Bastien Nocera <hadess hadess net>
Date: Wed Mar 18 18:15:35 2015 +0100
network: Fix warning on panel exit
Now that the VPN object is getting finalized, make sure not to warn if
the NMClient is already gone.
https://bugzilla.gnome.org/show_bug.cgi?id=746411
panels/network/net-vpn.c | 8 +++++---
1 files changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/panels/network/net-vpn.c b/panels/network/net-vpn.c
index 98acb2c..c6fdda1 100644
--- a/panels/network/net-vpn.c
+++ b/panels/network/net-vpn.c
@@ -503,9 +503,11 @@ net_vpn_finalize (GObject *object)
NetVpnPrivate *priv = vpn->priv;
NMClient *client = net_object_get_client (NET_OBJECT (object));
- g_signal_handlers_disconnect_by_func (client,
- nm_active_connections_changed,
- vpn);
+ if (client) {
+ g_signal_handlers_disconnect_by_func (client,
+ nm_active_connections_changed,
+ vpn);
+ }
if (priv->active_connection) {
g_signal_handlers_disconnect_by_func (priv->active_connection,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]