mirror of
https://github.com/subsurface/subsurface.git
synced 2024-12-01 06:30:26 +00:00
Add quick hack for "no sample pressure but tank index changed" case
This isn't right if you switch back to the same cylinder multiple times, but for the first time it kind of works - just take the beginning cylinder pressure if we have one. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
45d4d5ecde
commit
e919a0f2ea
1 changed files with 2 additions and 0 deletions
|
@ -719,6 +719,8 @@ static struct plot_info *create_plot_info(struct dive *dive)
|
|||
entry->same_cylinder = sample->cylinderindex == cylinderindex;
|
||||
cylinderindex = sample->cylinderindex;
|
||||
entry->pressure = sample->cylinderpressure.mbar;
|
||||
if (!entry->same_cylinder && !entry->pressure)
|
||||
entry->pressure = dive->cylinder[cylinderindex].start.mbar;
|
||||
entry->temperature = sample->temperature.mkelvin;
|
||||
|
||||
if (depth || lastdepth)
|
||||
|
|
Loading…
Reference in a new issue