From 4bbe5646a5af95d82759f10d2177b05701400bdc Mon Sep 17 00:00:00 2001 From: Berthold Stoeger Date: Tue, 1 Nov 2022 12:12:19 +0100 Subject: [PATCH] cleanup: remove unused declarations in planner.h Most of these declared non existing functions or pointers. One [get_gas_idx()] was only used in one source file and doesn't have to be globally accessible Signed-off-by: Berthold Stoeger --- core/planner.c | 2 +- core/planner.h | 9 --------- 2 files changed, 1 insertion(+), 10 deletions(-) diff --git a/core/planner.c b/core/planner.c index 598e568bf..a4c93ba77 100644 --- a/core/planner.c +++ b/core/planner.c @@ -92,7 +92,7 @@ int get_cylinderid_at_time(struct dive *dive, struct divecomputer *dc, duration_ return cylinder_idx; } -int get_gasidx(struct dive *dive, struct gasmix mix) +static int get_gasidx(struct dive *dive, struct gasmix mix) { return find_best_gasmix_match(mix, &dive->cylinders); } diff --git a/core/planner.h b/core/planner.h index 6d0353db0..48d2bb33f 100644 --- a/core/planner.h +++ b/core/planner.h @@ -42,22 +42,13 @@ extern "C" { extern int validate_gas(const char *text, struct gasmix *gas); extern int validate_po2(const char *text, int *mbar_po2); -extern timestamp_t current_time_notz(void); -extern void set_last_stop(bool last_stop_6m); -extern void set_verbatim(bool verbatim); -extern void set_display_runtime(bool display); -extern void set_display_duration(bool display); -extern void set_display_transitions(bool display); extern int get_cylinderid_at_time(struct dive *dive, struct divecomputer *dc, duration_t time); -extern int get_gasidx(struct dive *dive, struct gasmix mix); extern bool diveplan_empty(struct diveplan *diveplan); extern void add_plan_to_notes(struct diveplan *diveplan, struct dive *dive, bool show_disclaimer, int error); extern const char *get_planner_disclaimer(); extern char *get_planner_disclaimer_formatted(); extern void free_dps(struct diveplan *diveplan); -extern struct dive *planned_dive; -extern char *cache_data; struct divedatapoint *plan_add_segment(struct diveplan *diveplan, int duration, int depth, int cylinderid, int po2, bool entered, enum divemode_t divemode); struct divedatapoint *create_dp(int time_incr, int depth, int cylinderid, int po2);