diff options
author | Linux Build Service Account <lnxbuild@localhost> | 2016-03-05 03:00:39 -0800 |
---|---|---|
committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2016-03-05 03:00:39 -0800 |
commit | cde457831ca6912133a3737bcfaddccd27557d1d (patch) | |
tree | e53abd62288d925e51503165f119c1aac63e0d24 | |
parent | 27064321e4016f5e6a77a8c56ecfd3e50fc6bf38 (diff) | |
parent | e27390257a37b691b99ab96ab61326ca1f6a9239 (diff) | |
download | android_system_bt-cde457831ca6912133a3737bcfaddccd27557d1d.tar.gz android_system_bt-cde457831ca6912133a3737bcfaddccd27557d1d.tar.bz2 android_system_bt-cde457831ca6912133a3737bcfaddccd27557d1d.zip |
Merge "Bluetooth: Synchronizing access to hashmap in counter module"
-rw-r--r-- | btcore/src/counter.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/btcore/src/counter.c b/btcore/src/counter.c index b88c7a27e..92248b237 100644 --- a/btcore/src/counter.c +++ b/btcore/src/counter.c @@ -136,7 +136,9 @@ static future_t *counter_init(void) { static future_t *counter_clean_up(void) { counter_socket_close(); + pthread_mutex_lock(&hash_map_lock_); hash_map_free(hash_map_counter_); + pthread_mutex_unlock(&hash_map_lock_); pthread_mutex_destroy(&hash_map_lock_); hash_map_counter_ = NULL; return future_new_immediate(FUTURE_SUCCESS); |