From 69b5961c1ceba53e2222c35728208ebe15c92d12 Mon Sep 17 00:00:00 2001 From: Giulio Eulisse <10544+ktf@users.noreply.github.com> Date: Fri, 19 Apr 2024 14:57:58 +0200 Subject: [PATCH] DPL: Fix memory leak in variant_helper --- Framework/Core/include/Framework/Variant.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Framework/Core/include/Framework/Variant.h b/Framework/Core/include/Framework/Variant.h index b8be3a780547e..54e4b54be9606 100644 --- a/Framework/Core/include/Framework/Variant.h +++ b/Framework/Core/include/Framework/Variant.h @@ -285,7 +285,7 @@ struct variant_helper { template struct variant_helper { - static std::string get(const S* store) { return std::string(strdup(*reinterpret_cast(store))); } + static std::string get(const S* store) { return std::string(*reinterpret_cast(store)); } static void set(S* store, std::string value) { *reinterpret_cast(store) = strdup(value.data()); } };