From: Thomas Egerer Date: Mon, 21 Mar 2016 13:46:11 +0000 (+0100) Subject: ha: Delete cache entry inside the locked mutex X-Git-Tag: 5.4.1dr1~21 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=90a7a68488e25e59b4b3cbccd189ed66b5804894;p=thirdparty%2Fstrongswan.git ha: Delete cache entry inside the locked mutex Signed-off-by: Thomas Egerer --- diff --git a/src/libcharon/plugins/ha/ha_cache.c b/src/libcharon/plugins/ha/ha_cache.c index 0650f7fd96..832dcf4acb 100644 --- a/src/libcharon/plugins/ha/ha_cache.c +++ b/src/libcharon/plugins/ha/ha_cache.c @@ -186,11 +186,13 @@ METHOD(ha_cache_t, delete_, void, { entry_t *entry; + this->mutex->lock(this->mutex); entry = this->cache->remove(this->cache, ike_sa); if (entry) { entry_destroy(entry); } + this->mutex->unlock(this->mutex); } /**