cddl/contrib/opensolaris/lib/libuutil/common/uu_avl.c
Fix a memory leak in uu_avl_pool_create: pthread_mutex_init without a corresponding pthread_mutex_destroy. It shows up, among other places, when doing "zfs list". MFC after: 3 weeks Sponsored by: Spectra Logic Corporation
This commit is contained in:
parent
073972f1a9
commit
2d7c8761fc
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=262912
@ -128,6 +128,7 @@ uu_avl_pool_destroy(uu_avl_pool_t *pp)
|
|||||||
pp->uap_next->uap_prev = pp->uap_prev;
|
pp->uap_next->uap_prev = pp->uap_prev;
|
||||||
pp->uap_prev->uap_next = pp->uap_next;
|
pp->uap_prev->uap_next = pp->uap_next;
|
||||||
(void) pthread_mutex_unlock(&uu_apool_list_lock);
|
(void) pthread_mutex_unlock(&uu_apool_list_lock);
|
||||||
|
(void) pthread_mutex_destroy(&pp->uap_lock);
|
||||||
pp->uap_prev = NULL;
|
pp->uap_prev = NULL;
|
||||||
pp->uap_next = NULL;
|
pp->uap_next = NULL;
|
||||||
uu_free(pp);
|
uu_free(pp);
|
||||||
|
Loading…
Reference in New Issue
Block a user