[network-manager-applet/th/vpn-service-info-bgo767197: 5/8] c-e: don't assert for existing plugin in vpn_supports_ipv6()



commit e5271656e825c59589b44c66efebd3773e4f1114
Author: Thomas Haller <thaller redhat com>
Date:   Wed Jun 8 13:12:49 2016 +0200

    c-e: don't assert for existing plugin in vpn_supports_ipv6()

 src/connection-editor/vpn-helpers.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/src/connection-editor/vpn-helpers.c b/src/connection-editor/vpn-helpers.c
index 838450a..5031d83 100644
--- a/src/connection-editor/vpn-helpers.c
+++ b/src/connection-editor/vpn-helpers.c
@@ -332,7 +332,8 @@ vpn_supports_ipv6 (NMConnection *connection)
        g_return_val_if_fail (service_type != NULL, FALSE);
 
        plugin = vpn_get_plugin_by_service (service_type);
-       g_return_val_if_fail (plugin != NULL, FALSE);
+       if (!plugin)
+               return FALSE;
 
        capabilities = nm_vpn_editor_plugin_get_capabilities (plugin);
        return (capabilities & NM_VPN_EDITOR_PLUGIN_CAPABILITY_IPV6) != 0;


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