From 2743e59415f81522f4b0ce9bb2b25243c6ef18e6 Mon Sep 17 00:00:00 2001 From: Berthold Stoeger Date: Mon, 4 Feb 2019 22:16:44 +0100 Subject: [PATCH] Cleanup: remove unsused function clear_dive_site() The last caller was removed in 11a211fb02ad5443342d91b6967f150cb4f6d34f Signed-off-by: Berthold Stoeger --- core/divesite.c | 15 --------------- core/divesite.h | 1 - 2 files changed, 16 deletions(-) diff --git a/core/divesite.c b/core/divesite.c index f81d6abf6..25ec82ef3 100644 --- a/core/divesite.c +++ b/core/divesite.c @@ -281,21 +281,6 @@ void merge_dive_site(struct dive_site *a, struct dive_site *b) } } -void clear_dive_site(struct dive_site *ds) -{ - free(ds->name); - free(ds->notes); - free(ds->description); - ds->name = NULL; - ds->notes = NULL; - ds->description = NULL; - ds->location.lat.udeg = 0; - ds->location.lon.udeg = 0; - ds->uuid = 0; - ds->taxonomy.nr = 0; - free_taxonomy(&ds->taxonomy); -} - void merge_dive_sites(struct dive_site *ref, struct dive_site *dive_sites[], int count) { int curr_dive, i; diff --git a/core/divesite.h b/core/divesite.h index a7dca6b0f..971eb6711 100644 --- a/core/divesite.h +++ b/core/divesite.h @@ -68,7 +68,6 @@ bool dive_site_is_empty(struct dive_site *ds); void copy_dive_site_taxonomy(struct dive_site *orig, struct dive_site *copy); void copy_dive_site(struct dive_site *orig, struct dive_site *copy); void merge_dive_site(struct dive_site *a, struct dive_site *b); -void clear_dive_site(struct dive_site *ds); unsigned int get_distance(const location_t *loc1, const location_t *loc2); struct dive_site *find_or_create_dive_site_with_name(const char *name, timestamp_t divetime); void merge_dive_sites(struct dive_site *ref, struct dive_site *dive_sites[], int count);