summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2015-10-05 16:39:12 +0100
committerGravatar Dirk Hohndel <dirk@hohndel.org>2015-10-06 00:01:29 +0100
commitc50fc04a825a009f107f798a47463e8a45fa5927 (patch)
treeac86b31a55edcbc4b407da561bca0b33bfcccff7
parentc6eb747d0dccad002f63ab8aef0518e2dfe10a3e (diff)
downloadsubsurface-c50fc04a825a009f107f798a47463e8a45fa5927.tar.gz
Reset some more values in split_dive_at()
Otherwise fixup_dive() won't update them. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
-rw-r--r--dive.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/dive.c b/dive.c
index 2ed90f284..215789522 100644
--- a/dive.c
+++ b/dive.c
@@ -2915,6 +2915,14 @@ static int split_dive_at(struct dive *dive, int a, int b)
dc2->maxdepth.mm = 0;
d1->maxdepth.mm = 0;
d2->maxdepth.mm = 0;
+ d1->duration.seconds = 0;
+ d2->duration.seconds = 0;
+ d1->watertemp.mkelvin = 0;
+ d2->watertemp.mkelvin = 0;
+ d1->maxtemp.mkelvin = 0;
+ d2->maxtemp.mkelvin = 0;
+ d1->mintemp.mkelvin = 0;
+ d2->mintemp.mkelvin = 0;
fixup_dive(d1);
fixup_dive(d2);