summaryrefslogtreecommitdiffstats
path: root/dive.c
diff options
context:
space:
mode:
Diffstat (limited to 'dive.c')
-rw-r--r--dive.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/dive.c b/dive.c
index b5fb1382e..8d1c71639 100644
--- a/dive.c
+++ b/dive.c
@@ -1251,6 +1251,8 @@ static void free_events(struct event *ev)
static void free_dc(struct divecomputer *dc)
{
free(dc->sample);
+ if (dc->model)
+ free((void *)dc->model);
free_events(dc->events);
free(dc);
}