summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--divelist.c3
-rw-r--r--info.c2
2 files changed, 4 insertions, 1 deletions
diff --git a/divelist.c b/divelist.c
index 8cf079391..36c5883b1 100644
--- a/divelist.c
+++ b/divelist.c
@@ -565,7 +565,8 @@ static void fill_one_dive(struct dive *dive,
DIVE_SUIT, suit,
-1);
- /* this will create a merge conflict with the memory leak patches */
+ free(location);
+ free(cylinder);
free(suit);
}
diff --git a/info.c b/info.c
index 09d61c835..a28e79390 100644
--- a/info.c
+++ b/info.c
@@ -243,6 +243,8 @@ static gboolean match_string_entry(GtkTreeModel *model, GtkTreePath *path, GtkTr
gtk_tree_model_get(model, iter, 0, &entry, -1);
cmp = strcmp(entry, string);
+ if (entry)
+ free(entry);
/* Stop. The entry is bigger than the new one */
if (cmp > 0)