+static void save_depths(FILE *f, struct dive *dive)
+{
+ /* What's the point of this dive entry again? */
+ if (!dive->maxdepth.mm && !dive->meandepth.mm)
+ return;
+
+ fputs(" <depth", f);
+ show_depth(f, dive->maxdepth, " max='", "'");
+ show_depth(f, dive->meandepth, " mean='", "'");
+ fputs(" />\n", f);
+}
+
+static void save_temperatures(FILE *f, struct dive *dive)
+{
+ if (!dive->airtemp.mkelvin && !dive->watertemp.mkelvin)
+ return;
+ fputs(" <temperature", f);
+ show_temperature(f, dive->airtemp, " air='", "'");
+ show_temperature(f, dive->watertemp, " water='", "'");
+ fputs(" />\n", f);
+}
+