From 6e343c734af619e620962f2ab26862c5c416300a Mon Sep 17 00:00:00 2001 From: Berthold Stoeger Date: Wed, 25 Sep 2019 20:17:41 +0200 Subject: Core: implement move functions for dive and dive_site table To allow efficient moving of downloaded dives from the download thread to the model, implement a general move function that moves table data. Instantiate that function for the dive and dive_site tables. Signed-off-by: Berthold Stoeger --- core/divesite.c | 1 + 1 file changed, 1 insertion(+) (limited to 'core/divesite.c') diff --git a/core/divesite.c b/core/divesite.c index 68ac6e98a..0ed4eb2ca 100644 --- a/core/divesite.c +++ b/core/divesite.c @@ -131,6 +131,7 @@ static MAKE_GET_IDX(dive_site_table, struct dive_site *, dive_sites) MAKE_SORT(dive_site_table, struct dive_site *, dive_sites, compare_sites) static MAKE_REMOVE(dive_site_table, struct dive_site *, dive_site) MAKE_CLEAR_TABLE(dive_site_table, dive_sites, dive_site) +MAKE_MOVE_TABLE(dive_site_table, dive_sites) int add_dive_site_to_table(struct dive_site *ds, struct dive_site_table *ds_table) { -- cgit v1.2.3-70-g09d2