From 1b2a9e03c32afc82099e87550db22ee2c7347686 Mon Sep 17 00:00:00 2001 From: Michal Mielewczyk Date: Mon, 7 Oct 2024 10:10:43 +0200 Subject: [PATCH] Add missing cache unlock in init rollback Signed-off-by: Michal Mielewczyk --- src/mngt/ocf_mngt_cache.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/mngt/ocf_mngt_cache.c b/src/mngt/ocf_mngt_cache.c index 67466bcf..d1c8ad76 100644 --- a/src/mngt/ocf_mngt_cache.c +++ b/src/mngt/ocf_mngt_cache.c @@ -1468,6 +1468,9 @@ static void _ocf_mngt_init_handle_error(ocf_ctx_t ctx, env_mutex_destroy(&cache->flush_mutex); + if (params->flags.cache_locked) + ocf_mngt_cache_unlock(cache); + ocf_mngt_cache_lock_deinit(cache); if (params->flags.metadata_inited)