Commit c3255ed7 authored by Thomas Haller's avatar Thomas Haller

applet: remove assert(s_con) from applet_get_active_vpn_connection()

This assertion is just to strict. On client side, we cannot expect that
all connections that NetworkManager exposes are valid.

In libnm/libnm-glib there was an old bug, that connections which don't verify
could be completely bogus and thus hit this assertion. This got fixed by
and with a fixed libnm/libnm-glib, we would always expect that a
connection has at least a NMSettingConnection instance.

Nonetheless, there is no reason to enforce that with an assert.

This was already fixed before by 22468c05
and reverted again by c86d6663.
parent 2af8361c
......@@ -1112,7 +1112,8 @@ applet_get_active_vpn_connection (NMApplet *applet,
s_con = nm_connection_get_setting_connection (connection);
g_assert (s_con);
if (!s_con)
if (!strcmp (nm_setting_connection_get_connection_type (s_con), NM_SETTING_VPN_SETTING_NAME)) {
ret = candidate;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment