diff options
Diffstat (limited to 'dive.c')
-rw-r--r-- | dive.c | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -2369,6 +2369,9 @@ int average_depth(struct diveplan *dive) int last_depth = 0; struct divedatapoint *dp = dive->dp; + if (!dp) + return 0; + while (dp) { if (dp->time) { /* Ignore gas indication samples */ |