From e2cdb618ae77851388acba04c74f7afdaddb7592 Mon Sep 17 00:00:00 2001 From: "H. Joe Lee" Date: Wed, 6 Oct 2021 16:25:40 -0500 Subject: OESS-168: Remove clang warnings. (#1074) * OESS-168: Remove clang warnings. * Committing clang-format changes Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com> --- tools/lib/h5diff_array.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/lib/h5diff_array.c b/tools/lib/h5diff_array.c index 2d6c66c..e16a045 100644 --- a/tools/lib/h5diff_array.c +++ b/tools/lib/h5diff_array.c @@ -2070,7 +2070,7 @@ diff_ldouble_element(unsigned char *mem1, unsigned char *mem2, hsize_t elem_idx, /* both not NaN, do the comparison */ if (!isnan1 && !isnan2) { - if (ABS(temp1_double - temp2_double) > opts->delta) { + if ((double)ABS(temp1_double - temp2_double) > opts->delta) { opts->print_percentage = 0; print_pos(opts, elem_idx, 0); if (print_data(opts)) { @@ -2163,7 +2163,7 @@ diff_ldouble_element(unsigned char *mem1, unsigned char *mem2, hsize_t elem_idx, } nfound++; } - else if (per > opts->percent && ABS(temp1_double - temp2_double) > opts->delta) { + else if (per > opts->percent && (double)ABS(temp1_double - temp2_double) > opts->delta) { opts->print_percentage = 1; print_pos(opts, elem_idx, 0); if (print_data(opts)) { -- cgit v0.12