From a6d772ac62b8391505b89725a41da5615b77743a Mon Sep 17 00:00:00 2001 From: Veronika Molnarova Date: Fri, 19 Apr 2024 15:48:56 +0200 Subject: [PATCH] Fix memory leak, forgotten freeing of the memory --- src/nfa/operations.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/nfa/operations.cc b/src/nfa/operations.cc index 3de3dad65..8e2594c67 100644 --- a/src/nfa/operations.cc +++ b/src/nfa/operations.cc @@ -228,8 +228,10 @@ namespace { covering_states.push_back(mata::utils::OrdVector()); covering_indexes.push_back(mata::utils::OrdVector()); - if (aut.delta.empty()) + if (aut.delta.empty()){ + delete subset_map; return result; + } using Iterator = mata::utils::OrdVector::const_iterator; SynchronizedExistentialSymbolPostIterator synchronized_iterator;