summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Biebl <biebl@debian.org>2018-10-09 00:10:14 +0200
committerMichael Biebl <biebl@debian.org>2018-10-09 00:16:32 +0200
commit29a9e38e2d659b12161d86bea6cf61a6091521f1 (patch)
treee5fe7eff8842f39c4791f3e041db911a588938e2
parent8fb79ad7892267b481a5a1ad892d19ae5abbcea5 (diff)
libnm: Fix accessing enabled and metered properties
Those properties were proxied to the wrong object leading to a crash of clients using libnm. Closes: #892998
-rw-r--r--debian/patches/libnm-client-proxy-_enabled-and-metered-properties-to-the.patch54
-rw-r--r--debian/patches/series1
2 files changed, 55 insertions, 0 deletions
diff --git a/debian/patches/libnm-client-proxy-_enabled-and-metered-properties-to-the.patch b/debian/patches/libnm-client-proxy-_enabled-and-metered-properties-to-the.patch
new file mode 100644
index 0000000..5287b86
--- /dev/null
+++ b/debian/patches/libnm-client-proxy-_enabled-and-metered-properties-to-the.patch
@@ -0,0 +1,54 @@
+From: Lubomir Rintel <lkundrak@v3.sk>
+Date: Wed, 1 Nov 2017 21:29:39 +0100
+Subject: libnm/client: proxy *_enabled and metered properties to the right
+ object
+
+They're provided by the Manager, not by the RemoteSettings.
+
+(cherry picked from commit c81005b84650b8e6d709ce6afda96fb55987cdb8)
+(cherry picked from commit 34035ceee8e75d8cb7deb6f4aa211067bddcfe97)
+(cherry picked from commit b2af5f7ab676675a496adfa08541ecca43a9d9f8)
+---
+ libnm/nm-client.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/libnm/nm-client.c b/libnm/nm-client.c
+index 63eaa84..ba13347 100644
+--- a/libnm/nm-client.c
++++ b/libnm/nm-client.c
+@@ -2616,7 +2616,7 @@ get_property (GObject *object, guint prop_id,
+ break;
+ case PROP_WIRELESS_HARDWARE_ENABLED:
+ if (priv->manager)
+- g_object_get_property (G_OBJECT (priv->settings), pspec->name, value);
++ g_object_get_property (G_OBJECT (priv->manager), pspec->name, value);
+ else
+ g_value_set_boolean (value, FALSE);
+ break;
+@@ -2625,7 +2625,7 @@ get_property (GObject *object, guint prop_id,
+ break;
+ case PROP_WWAN_HARDWARE_ENABLED:
+ if (priv->manager)
+- g_object_get_property (G_OBJECT (priv->settings), pspec->name, value);
++ g_object_get_property (G_OBJECT (priv->manager), pspec->name, value);
+ else
+ g_value_set_boolean (value, FALSE);
+ break;
+@@ -2634,7 +2634,7 @@ get_property (GObject *object, guint prop_id,
+ break;
+ case PROP_WIMAX_HARDWARE_ENABLED:
+ if (priv->manager)
+- g_object_get_property (G_OBJECT (priv->settings), pspec->name, value);
++ g_object_get_property (G_OBJECT (priv->manager), pspec->name, value);
+ else
+ g_value_set_boolean (value, FALSE);
+ break;
+@@ -2655,7 +2655,7 @@ get_property (GObject *object, guint prop_id,
+ break;
+ case PROP_METERED:
+ if (priv->manager)
+- g_object_get_property (G_OBJECT (priv->settings), pspec->name, value);
++ g_object_get_property (G_OBJECT (priv->manager), pspec->name, value);
+ else
+ g_value_set_uint (value, NM_METERED_UNKNOWN);
+ break;
diff --git a/debian/patches/series b/debian/patches/series
index 7df065a..e5e2ccc 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -20,3 +20,4 @@ wifi-also-show-the-NM-D-Bus-path-for-the-Wi-Fi-AP-in-nm_w.patch
device-separately-handle-NMDevice-s-autoconnect-by-user-a.patch
device-add-get_autoconnect_allowed-virtual-function.patch
device-wifi-block-autoconnect-while-scanning-is-in-progre.patch
+libnm-client-proxy-_enabled-and-metered-properties-to-the.patch