From: Emil Velikov Date: Thu, 8 May 2014 18:09:39 +0000 (+0100) Subject: ilo: destroy the mutex, if winsys creation fails X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=42770ff94ea8a30de51d4887611fc94bf271cde4;p=mesa.git ilo: destroy the mutex, if winsys creation fails Signed-off-by: Emil Velikov Reviewed-by: Chia-I Wu --- diff --git a/src/gallium/winsys/intel/drm/intel_drm_winsys.c b/src/gallium/winsys/intel/drm/intel_drm_winsys.c index d34246af9eb..00c4a46c214 100644 --- a/src/gallium/winsys/intel/drm/intel_drm_winsys.c +++ b/src/gallium/winsys/intel/drm/intel_drm_winsys.c @@ -181,6 +181,7 @@ intel_winsys_create_for_fd(int fd) pipe_mutex_init(winsys->mutex); if (!probe_winsys(winsys)) { + pipe_mutex_destroy(winsys->mutex); drm_intel_bufmgr_destroy(winsys->bufmgr); FREE(winsys); return NULL;