summaryrefslogtreecommitdiff
path: root/network/NetworkManager/patches/examples-fix-querying-active-connections.patch
diff options
context:
space:
mode:
Diffstat (limited to 'network/NetworkManager/patches/examples-fix-querying-active-connections.patch')
-rw-r--r--network/NetworkManager/patches/examples-fix-querying-active-connections.patch33
1 files changed, 33 insertions, 0 deletions
diff --git a/network/NetworkManager/patches/examples-fix-querying-active-connections.patch b/network/NetworkManager/patches/examples-fix-querying-active-connections.patch
new file mode 100644
index 0000000000..9598cadf76
--- /dev/null
+++ b/network/NetworkManager/patches/examples-fix-querying-active-connections.patch
@@ -0,0 +1,33 @@
+From 14617f6916124d29f65e380a3602746841203a57 Mon Sep 17 00:00:00 2001
+From: Dan Williams <dcbw@redhat.com>
+Date: Tue, 23 Nov 2010 16:28:25 -0600
+Subject: [PATCH 2/4] examples: fix querying active connections
+
+---
+ examples/python/nm-state.py | 6 +++---
+ 1 files changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/examples/python/nm-state.py b/examples/python/nm-state.py
+index fddd2da..2bbdd2d 100644
+--- a/examples/python/nm-state.py
++++ b/examples/python/nm-state.py
+@@ -47,13 +47,13 @@ active = manager_prop_iface.Get("org.freedesktop.NetworkManager", "ActiveConnect
+ for a in active:
+ ac_proxy = bus.get_object("org.freedesktop.NetworkManager", a)
+ prop_iface = dbus.Interface(ac_proxy, "org.freedesktop.DBus.Properties")
+- state = prop_iface.Get("org.freedesktop.NetworkManager.ActiveConnection", "State")
++ state = prop_iface.Get("org.freedesktop.NetworkManager.Connection.Active", "State")
+
+ # Connections in NM are a collection of settings that describe everything
+ # needed to connect to a specific network. Lets get those details so we
+ # can find the user-readable name of the connection.
+- con_path = prop_iface.Get("org.freedesktop.NetworkManager.ActiveConnection", "Connection")
+- con_service = prop_iface.Get("org.freedesktop.NetworkManager.ActiveConnection", "ServiceName")
++ con_path = prop_iface.Get("org.freedesktop.NetworkManager.Connection.Active", "Connection")
++ con_service = prop_iface.Get("org.freedesktop.NetworkManager.Connection.Active", "ServiceName")
+
+ # ask the provider of the connection for its details
+ service_proxy = bus.get_object(con_service, con_path)
+--
+1.7.3.4
+