OSDN Git Service

Use the correct memory free function within HCI layer shutdown
authorPavlin Radoslavov <pavlin@google.com>
Wed, 1 Jul 2015 04:39:11 +0000 (21:39 -0700)
committerPavlin Radoslavov <pavlin@google.com>
Wed, 1 Jul 2015 04:39:11 +0000 (21:39 -0700)
The  entries on the "command_queue" are allocated by osi_calloc()
hence they should be deallocated by osi_free()

Bug: 21784321
Change-Id: Ic6e13dbafef2c6ac79ce74ebfc4db702c9ef04c5

hci/src/hci_layer.c

index 89d5cc9..5138ce6 100644 (file)
@@ -287,7 +287,7 @@ static future_t *shut_down() {
     thread_join(thread);
   }
 
-  fixed_queue_free(command_queue, buffer_allocator->free);
+  fixed_queue_free(command_queue, osi_free);
   fixed_queue_free(packet_queue, buffer_allocator->free);
   list_free(commands_pending_response);