[PATCH] Fix a crash when creating a device from storage

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The list "services" is just a list of the object paths of the
registered services that a device has. When we want to store
the primary services information we need to store the "primaries"
list, that contain all the primary services information.
---
 src/device.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/device.c b/src/device.c
index b0a6542..9b8591b 100644
--- a/src/device.c
+++ b/src/device.c
@@ -1567,7 +1567,7 @@ static void store_services(struct btd_device *device)
 {
 	struct btd_adapter *adapter = device->adapter;
 	bdaddr_t dba, sba;
-	char *str = primary_list_to_string(device->services);
+	char *str = primary_list_to_string(device->primaries);
 
 	adapter_get_address(adapter, &sba);
 	device_get_address(device, &dba);
-- 
1.7.4.3

--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux