[network-manager-netbook] Fix the active connection updating for the case when there's no ACs.
- From: Tambet Ingo <tambeti src gnome org>
- To: svn-commits-list gnome org
- Subject: [network-manager-netbook] Fix the active connection updating for the case when there's no ACs.
- Date: Wed, 27 May 2009 07:44:39 -0400 (EDT)
commit 8007a1577de9bd58658f4e1cdfcb63f5f8a6a464
Author: Tambet Ingo <tambet gmail com>
Date: Wed May 27 12:03:20 2009 +0300
Fix the active connection updating for the case when there's no ACs.
---
src/nmn-networks.c | 5 +----
1 files changed, 1 insertions(+), 4 deletions(-)
diff --git a/src/nmn-networks.c b/src/nmn-networks.c
index 85d37e1..75b7903 100644
--- a/src/nmn-networks.c
+++ b/src/nmn-networks.c
@@ -58,14 +58,11 @@ find_ac_for_item (NmnNetworks *self, NmnNetworkItem *item)
int i;
acs = nm_client_get_active_connections (NM_CLIENT (priv->nm_data));
- if (!acs)
- return;
-
connection = nm_exported_connection_get_connection (nmn_network_item_get_connection (item));
path = nm_connection_get_path (connection);
scope = nm_connection_get_scope (connection);
- for (i = 0; i < acs->len; i++) {
+ for (i = 0; acs && i < acs->len; i++) {
NMActiveConnection *ac = g_ptr_array_index (acs, i);
if (scope == nm_active_connection_get_scope (ac) &&
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]