Merge branch 'webservice-import'

Update maxdepth / duration that have moved into the divecomputer
structure.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2013-01-24 12:05:16 -08:00
commit 100c400809
4 changed files with 37 additions and 3 deletions

5
main.c
View file

@ -165,7 +165,10 @@ void report_dives(gboolean is_imported, gboolean prefer_imported)
struct dive *dive = pp[1];
struct dive *merged;
if (prev->when + prev->dc.duration.seconds < dive->when)
/* only try to merge overlapping dives - or if one of the dives has
* zero duration (that might be a gps marker from the webservice) */
if (prev->dc.duration.seconds && dive->dc.duration.seconds &&
prev->when + prev->dc.duration.seconds < dive->when)
continue;
merged = try_to_merge(prev, dive, prefer_imported);