If device is paired but not bonded than Paired property should be
also updated when device is disconnected.
Change-Id: Ic4b49d25692dd09807196444f20be76212b96b30
Signed-off-by: Amit Purwar <amit.purwar@samsung.com>
dbus_message_unref(msg);
}
- if (state->paired && !state->bonded)
+ if (state->paired && !state->bonded) {
btd_adapter_remove_bonding(device->adapter, &device->bdaddr,
bdaddr_type);
+ state->paired = false;
+
+ /* report change only if both bearers are unpaired */
+ if (!device->bredr_state.paired && !device->le_state.paired)
+ g_dbus_emit_property_changed(dbus_conn, device->path,
+ DEVICE_INTERFACE,
+ "Paired");
+ }
+
#ifndef TIZEN_FEATURE_BLUEZ_MODIFY
if (device->bredr_state.connected || device->le_state.connected)