aboutsummaryrefslogtreecommitdiffstats
path: root/plugins
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@intel.com>2012-03-02 02:13:42 +0200
committerJohan Hedberg <johan.hedberg@intel.com>2012-03-02 02:13:42 +0200
commit4401737a3063628b9c2b6ec528ba8dc7007e2b00 (patch)
tree0e761413a94bea2600c06563d8dc271c6bbfe00c /plugins
parentc2ecc3efc76a9735f665faa25900dffe70fc0aa0 (diff)
downloadbluez-4401737a3063628b9c2b6ec528ba8dc7007e2b00.tar.gz
bluez-4401737a3063628b9c2b6ec528ba8dc7007e2b00.tar.xz
bluez-4401737a3063628b9c2b6ec528ba8dc7007e2b00.zip
mgmtops: Fix clearing of pending_uuids after g_slist_free_full()
Diffstat (limited to 'plugins')
-rw-r--r--plugins/mgmtops.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/plugins/mgmtops.c b/plugins/mgmtops.c
index 42a8a1f9..c91e9304 100644
--- a/plugins/mgmtops.c
+++ b/plugins/mgmtops.c
@@ -179,6 +179,7 @@ static void remove_controller(uint16_t index)
btd_manager_unregister_adapter(index);
g_slist_free_full(controllers[index].pending_uuids, g_free);
+ controllers[index].pending_uuids = NULL;
memset(&controllers[index], 0, sizeof(struct controller_info));
@@ -338,6 +339,7 @@ static int mgmt_update_powered(struct btd_adapter *adapter,
if (!mgmt_powered(settings)) {
btd_adapter_stop(adapter);
g_slist_free_full(info->pending_uuids, g_free);
+ info->pending_uuids = NULL;
info->pending_uuid = FALSE;
info->pending_class = FALSE;
return 0;