mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Clean double free in copy_dive_site()
This makes subsurface crash by simply clicking a dive in the list. Signed-off-by: Salvador Cuñat <salvador.cunat@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
f9c3142fa7
commit
097d65521a
1 changed files with 0 additions and 1 deletions
|
@ -171,7 +171,6 @@ void copy_dive_site(struct dive_site *orig, struct dive_site *copy)
|
||||||
copy->uuid = orig->uuid;
|
copy->uuid = orig->uuid;
|
||||||
if (orig->taxonomy.category == NULL) {
|
if (orig->taxonomy.category == NULL) {
|
||||||
free_taxonomy(copy->taxonomy.category);
|
free_taxonomy(copy->taxonomy.category);
|
||||||
free(copy->taxonomy.category);
|
|
||||||
copy->taxonomy.category = NULL;
|
copy->taxonomy.category = NULL;
|
||||||
copy->taxonomy.nr = 0;
|
copy->taxonomy.nr = 0;
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue