From e3d3b526e83ea99baae418fa895597b99f9704fa Mon Sep 17 00:00:00 2001 From: Arne Morten Kvarving Date: Fri, 22 Apr 2022 10:55:42 +0200 Subject: [PATCH] fixed: clear additional functions in clearProperties this is necessary to not register multiple functions if used in adaptive simulations --- src/SIM/SIMoutput.C | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/SIM/SIMoutput.C b/src/SIM/SIMoutput.C index b6f325ad..203a33cf 100644 --- a/src/SIM/SIMoutput.C +++ b/src/SIM/SIMoutput.C @@ -52,6 +52,9 @@ SIMoutput::~SIMoutput () void SIMoutput::clearProperties () { myPoints.clear(); + for (std::pair& func : myAddScalars) + delete func.second; + myAddScalars.clear(); this->SIMinput::clearProperties(); }