From 686391112fd42c615bcc4233472887a66a9b5a4a Mon Sep 17 00:00:00 2001 From: "Dr. David Alan Gilbert" Date: Mon, 3 Feb 2020 12:25:56 +0000 Subject: [PATCH] virtiofsd: load_capng missing unlock MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Missing unlock in error path. Fixes: Covertiy CID 1413123 Signed-off-by: Dr. David Alan Gilbert Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Stefan Hajnoczi --- tools/virtiofsd/passthrough_ll.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/virtiofsd/passthrough_ll.c b/tools/virtiofsd/passthrough_ll.c index e6f2399efc..c635fc8820 100644 --- a/tools/virtiofsd/passthrough_ll.c +++ b/tools/virtiofsd/passthrough_ll.c @@ -232,6 +232,7 @@ static int load_capng(void) */ cap.saved = capng_save_state(); if (!cap.saved) { + pthread_mutex_unlock(&cap.mutex); fuse_log(FUSE_LOG_ERR, "capng_save_state (thread)\n"); return -EINVAL; }