From a61b205aff182dac910918c8d72c8575791aa66c Mon Sep 17 00:00:00 2001 From: Quincey Koziol Date: Tue, 26 Sep 2000 15:29:40 -0500 Subject: [svn-r2597] Purpose: Fix compiler warning Description: "HUGE_VAL" (a double value) was being put into a float type and generating a warning during compile time. Solution: Replaced "HUGE_VAL" with "FLT_MAX" Platforms tested: FreeBSD 4.1 --- src/H5Tconv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/H5Tconv.c b/src/H5Tconv.c index 9cab897..16883b1 100644 --- a/src/H5Tconv.c +++ b/src/H5Tconv.c @@ -5904,12 +5904,12 @@ H5T_conv_double_float (hid_t src_id, hid_t dst_id, H5T_cdata_t *cdata, if (*((double*)s) > FLT_MAX) { if (!H5T_overflow_g || (H5T_overflow_g)(src_id, dst_id, s, d)<0) { - *((float*)d) = HUGE_VAL; + *((float*)d) = FLT_MAX; } } else if (*((double*)s) < -FLT_MAX) { if (!H5T_overflow_g || (H5T_overflow_g)(src_id, dst_id, s, d)<0) { - *((float*)d) = -HUGE_VAL; + *((float*)d) = -FLT_MAX; } } else { *((float*)d) = *((double*)s); -- cgit v0.12