mirror of
https://github.com/subsurface/subsurface.git
synced 2024-11-28 05:00:20 +00:00
Fix real memory leak
We can't keep the cache around (even though it's tempting) as the next iteration might change the start time of the planned dive or other parameters which would make the cached data invalid. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
3e8e005aa3
commit
c64227efe0
1 changed files with 2 additions and 0 deletions
|
@ -1445,6 +1445,8 @@ void DivePlannerPointsModel::createTemporaryPlan()
|
||||||
copy_samples(tempDive, current_dive);
|
copy_samples(tempDive, current_dive);
|
||||||
copy_events(tempDive, current_dive);
|
copy_events(tempDive, current_dive);
|
||||||
}
|
}
|
||||||
|
// throw away the cache
|
||||||
|
free(cache);
|
||||||
#if DEBUG_PLAN
|
#if DEBUG_PLAN
|
||||||
dump_plan(&diveplan);
|
dump_plan(&diveplan);
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in a new issue