From be9f9efb0eae6f09db4c61de7a5156b186dc2ad6 Mon Sep 17 00:00:00 2001 From: Berthold Stoeger Date: Sat, 9 Jan 2021 18:58:33 +0100 Subject: profile: pass dive to EventItem Don't access the global displayed_dive variable in an effort to make the profile reentrant. Note that this still accesses the global dc_number variable, which will likely have to be removed. Signed-off-by: Berthold Stoeger --- core/dive.h | 1 + 1 file changed, 1 insertion(+) (limited to 'core/dive.h') diff --git a/core/dive.h b/core/dive.h index a38236fc5..5bd5989d7 100644 --- a/core/dive.h +++ b/core/dive.h @@ -122,6 +122,7 @@ extern const char *get_dive_country(const struct dive *dive); extern const char *get_dive_location(const struct dive *dive); extern unsigned int number_of_computers(const struct dive *dive); extern struct divecomputer *get_dive_dc(struct dive *dive, int nr); +extern const struct divecomputer *get_dive_dc_const(const struct dive *dive, int nr); extern timestamp_t dive_endtime(const struct dive *dive); extern struct dive *make_first_dc(const struct dive *d, int dc_number); -- cgit v1.2.3-70-g09d2