Make sure init_decompression works for dive 0 as well
The loop would actually get entered for dive 0 and try to compare things with dive -1. Which of course fails. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
b94a93d061
commit
c8a9986451
@ -858,7 +858,7 @@ double init_decompression(struct dive *dive)
|
||||
;
|
||||
when = dive->when;
|
||||
i = divenr;
|
||||
while (--i) {
|
||||
while (i && --i) {
|
||||
struct dive* pdive = get_dive(i);
|
||||
/* we don't want to mix dives from different trips as we keep looking
|
||||
* for how far back we need to go */
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user