summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan Williams <dcbw@redhat.com>2015-10-23 11:50:12 -0500
committerThomas Haller <thaller@redhat.com>2015-10-25 19:52:39 +0100
commitcccb8fe5e6945085d43050411c1ced26453d85df (patch)
tree4540eae2566a3fd32b7abae2c99f0055c5b366c6
parent24195884cd953966776074cb6d8df6bf01641845 (diff)
bluetooth: fix missing 'connected' notifications (rh #1255284)
Because Bluez5 dropped DUN support, NM must do that manually which includes emulating the "connected" property for Bluetooth devices when DUN is used. It does this by setting priv->connected = TRUE in nm_bluez_device_connect_finish(). But for PAN, when NM does process the 'connected' property change notification, priv->connected is already TRUE and _take_variant_property_connected() does nothing. Hence the corresponding GObject property notification is not emitted, nm-device-bt.c::check_connect_continue() will never return success, and the activation times out. To fix this, ensure that GObject notifications are emitted when the device is connected, even if emulated internally. https://mail.gnome.org/archives/networkmanager-list/2015-October/msg00053.html https://bugzilla.redhat.com/show_bug.cgi?id=1255284 (cherry picked from commit 0e3086e8b885164f24b43a1060cb1f87a62723a8)
-rw-r--r--src/devices/bluetooth/nm-bluez-device.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/devices/bluetooth/nm-bluez-device.c b/src/devices/bluetooth/nm-bluez-device.c
index d5426052f6..89ad827077 100644
--- a/src/devices/bluetooth/nm-bluez-device.c
+++ b/src/devices/bluetooth/nm-bluez-device.c
@@ -603,8 +603,10 @@ nm_bluez_device_connect_finish (NMBluezDevice *self,
return NULL;
device = (const char *) g_simple_async_result_get_op_res_gpointer (simple);
- if (device && priv->bluez_version == 5)
+ if (device && priv->bluez_version == 5) {
priv->connected = TRUE;
+ g_object_notify (G_OBJECT (self), NM_BLUEZ_DEVICE_CONNECTED);
+ }
return device;
}