mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Really save airtemp and watertemp in the dive
I thought I had this fixed, but a silly thinko broke my fix. Only abort the saving if both air AND water temperature are already covered by the divecomputer(s) in a dive. If at least one of them is different, then create a divetemperature tag and fill in that value at the dive level. Fixes #313 Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
df464fcef1
commit
379fa5f652
1 changed files with 1 additions and 1 deletions
|
@ -155,7 +155,7 @@ static void save_dive_temperature(FILE *f, struct dive *dive)
|
|||
{
|
||||
if (!dive->airtemp.mkelvin && !dive->watertemp.mkelvin)
|
||||
return;
|
||||
if (dive->airtemp.mkelvin == dc_airtemp(&dive->dc) || dive->watertemp.mkelvin == dc_watertemp(&dive->dc))
|
||||
if (dive->airtemp.mkelvin == dc_airtemp(&dive->dc) && dive->watertemp.mkelvin == dc_watertemp(&dive->dc))
|
||||
return;
|
||||
|
||||
fputs(" <divetemperature", f);
|
||||
|
|
Loading…
Add table
Reference in a new issue