diff --git a/src/randomx.cpp b/src/randomx.cpp index 0b33806..7daaa46 100644 --- a/src/randomx.cpp +++ b/src/randomx.cpp @@ -134,9 +134,7 @@ extern "C" { void randomx_release_cache(randomx_cache* cache) { assert(cache != nullptr); - if (cache->memory != nullptr) { - cache->dealloc(cache); - } + cache->dealloc(cache); delete cache; }