Commit df404ff3 authored by Johannes Leins's avatar Johannes Leins
Browse files

explicitly calling destructor when clearing Measures in Cell

parent edca17ab
Pipeline #29918 passed with stage
in 56 seconds
......@@ -59,6 +59,9 @@ void Cell::addMeasure(Measure *measure) {
}
void Cell::clearMeasures() {
for(auto pairIDMeasure : measureByID) {
delete pairIDMeasure.second;
}
measureByID.clear();
}
......
......@@ -105,6 +105,10 @@ public:
double stockingRate = 0, bool fertilizerUsed = true,
bool mandatory = false, double payment = 0, bool insideOutMown = false, int cuttingHeight = 5);
~Measure() {
delete mowingPattern;
}
bool hasSchedule();
int getDuration();
bool isMandatory();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment