code cleanup: add empty table structures

It seemed to make sense to combine all three types in one commit.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2020-01-08 21:25:02 -08:00
parent 70cabb968c
commit e1cd055111
13 changed files with 47 additions and 41 deletions

View file

@ -380,9 +380,9 @@ void QMLManager::updateAllGlobalLists()
void QMLManager::mergeLocalRepo()
{
char *filename = NOCLOUD_LOCALSTORAGE;
struct dive_table table = { 0 };
struct trip_table trips = { 0 };
struct dive_site_table sites = { 0 };
struct dive_table table = empty_dive_table;
struct trip_table trips = empty_trip_table;
struct dive_site_table sites = empty_dive_site_table;
parse_file(filename, &table, &trips, &sites);
add_imported_dives(&table, &trips, &sites, IMPORT_MERGE_ALL_TRIPS);
}