summaryrefslogtreecommitdiffstats
path: root/profile.c
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2013-01-24 14:12:17 -0800
committerGravatar Dirk Hohndel <dirk@hohndel.org>2013-01-24 14:12:17 -0800
commit51880785afcb80e5ccaa3fdd6a796c5e1622d44a (patch)
tree171bf631c837f79501bdbec3bafa6e4a5b8f67e9 /profile.c
parent1bcc8dd9917c494077c56e6bfbaa36c2c045c2c2 (diff)
downloadsubsurface-51880785afcb80e5ccaa3fdd6a796c5e1622d44a.tar.gz
Only display temperature graph if we have temperature data
Commit b625332ca5ff "Display even constant temperature graph" was a little too aggressive. If we have no temperature data at all it caused us to plot a temperature line for absolute zero... Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'profile.c')
-rw-r--r--profile.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/profile.c b/profile.c
index 2dce8003b..4b04d68ce 100644
--- a/profile.c
+++ b/profile.c
@@ -883,7 +883,7 @@ static int setup_temperature_limits(struct graphics_context *gc, struct plot_inf
gc->bottomy = mintemp - delta / 3;
pi->endtempcoord = SCALEY(gc, pi->mintemp);
- return maxtemp >= mintemp;
+ return maxtemp && maxtemp >= mintemp;
}
static void plot_single_temp_text(struct graphics_context *gc, int sec, int mkelvin)