OSDN Git Service

core/device: Don't call btd_service_disconnect on device_remove
authorLuiz Augusto von Dentz <luiz.von.dentz@intel.com>
Tue, 9 Jul 2013 09:54:50 +0000 (12:54 +0300)
committerLuiz Augusto von Dentz <luiz.von.dentz@intel.com>
Wed, 10 Jul 2013 09:55:14 +0000 (12:55 +0300)
device_remove is called to cleanup/free the device objects so the
services should be disconnected before hand.

src/device.c

index dbaf548..88a7b86 100644 (file)
@@ -2381,8 +2381,6 @@ void device_remove(struct btd_device *device, gboolean remove_stored)
        if (device->browse)
                browse_request_cancel(device->browse);
 
-       g_slist_foreach(device->services, dev_disconn_service, NULL);
-
        while (device->services != NULL) {
                struct btd_service *service = device->services->data;