From: Yuval Shaia Date: Mon, 13 Apr 2020 08:57:38 +0000 (+0300) Subject: hw/rdma: Destroy list mutex when list is destroyed X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=a5cde048e865da81fdc9077f3af28a43bff78d35;p=qemu.git hw/rdma: Destroy list mutex when list is destroyed List mutex should be destroyed when gs list gets destroyed. Reported-by: Peter Maydell Signed-off-by: Yuval Shaia Message-Id: <20200413085738.11145-1-yuval.shaia.ml@gmail.com> Reviewed-by: Marcel Apfelbaum Signed-off-by: Marcel Apfelbaum --- diff --git a/hw/rdma/rdma_utils.c b/hw/rdma/rdma_utils.c index 73f279104c..698ed4716c 100644 --- a/hw/rdma/rdma_utils.c +++ b/hw/rdma/rdma_utils.c @@ -100,6 +100,7 @@ void rdma_protected_gslist_destroy(RdmaProtectedGSList *list) { if (list->list) { g_slist_free(list->list); + qemu_mutex_destroy(&list->lock); list->list = NULL; } }