From a3322c722f9876ecc7e7867685c2e6ae29406beb Mon Sep 17 00:00:00 2001 From: Johan Hedberg Date: Fri, 14 Dec 2012 10:29:05 +0200 Subject: [PATCH] core: Use "Services" instead of "Profiles" to store service UUIDs --- doc/settings-storage.txt | 6 +++--- src/adapter.c | 2 +- src/device.c | 6 +++--- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/doc/settings-storage.txt b/doc/settings-storage.txt index 792c89996..351b17e65 100644 --- a/doc/settings-storage.txt +++ b/doc/settings-storage.txt @@ -157,9 +157,9 @@ Long term key) related to a remote device. Blocked Boolean True if the remote device is blocked - Profiles List of List of profiles advertised by remote, - strings in 128-bits UUID format, separated by - ";" + Services List of List of service UUIDs advertised by + strings remote in 128-bits UUID format, + separated by ";" [DeviceID] group contains: diff --git a/src/adapter.c b/src/adapter.c index 20682cc68..323ba47d7 100644 --- a/src/adapter.c +++ b/src/adapter.c @@ -2314,7 +2314,7 @@ static void convert_ltk_entry(GKeyFile *key_file, void *value) static void convert_profiles_entry(GKeyFile *key_file, void *value) { g_strdelimit(value, " ", ';'); - g_key_file_set_string(key_file, "General", "Profiles", value); + g_key_file_set_string(key_file, "General", "Services", value); } static void convert_entry(char *key, char *value, void *user_data) diff --git a/src/device.c b/src/device.c index 96b226faa..7bde9701b 100644 --- a/src/device.c +++ b/src/device.c @@ -288,10 +288,10 @@ static gboolean store_device_info_cb(gpointer user_data) uuids = g_new0(gchar *, g_slist_length(device->uuids) + 1); for (i = 0, l = device->uuids; l; l = g_slist_next(l), i++) uuids[i] = l->data; - g_key_file_set_string_list(key_file, "General", "Profiles", + g_key_file_set_string_list(key_file, "General", "Services", (const gchar **)uuids, i); } else { - g_key_file_remove_key(key_file, "General", "Profiles", NULL); + g_key_file_remove_key(key_file, "General", "Services", NULL); } if (device->vendor_src) { @@ -1837,7 +1837,7 @@ next: device_block(device, FALSE); /* Load device profile list */ - uuids = g_key_file_get_string_list(key_file, "General", "Profiles", + uuids = g_key_file_get_string_list(key_file, "General", "Services", NULL, NULL); if (uuids) { gchar **uuid; -- 2.47.3