mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
mobile: set alloc_samples to 0 when resetting.
set alloc_samples = 0 when settings dc->sample = 0 and dc->samples = 0 Signed-off-by: Jan Iversen <jani@apache.org>
This commit is contained in:
parent
cabc5859fd
commit
49f3da3bfd
1 changed files with 2 additions and 0 deletions
|
@ -927,6 +927,7 @@ bool QMLManager::checkDuration(DiveObjectHelper *myDive, struct dive *d, QString
|
|||
free(d->dc.sample);
|
||||
d->dc.sample = 0;
|
||||
d->dc.samples = 0;
|
||||
d->dc.alloc_samples = 0;
|
||||
} else {
|
||||
appendTextToLog("Cannot change the duration on a dive that wasn't manually added");
|
||||
}
|
||||
|
@ -949,6 +950,7 @@ bool QMLManager::checkDepth(DiveObjectHelper *myDive, dive *d, QString depth)
|
|||
free(d->dc.sample);
|
||||
d->dc.sample = 0;
|
||||
d->dc.samples = 0;
|
||||
d->dc.alloc_samples = 0;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue