From 810349313ad320cd7df51a4d4579a4d5eb17927d Mon Sep 17 00:00:00 2001 From: Zdenek Kabelac Date: Mon, 15 Feb 2010 18:35:06 +0000 Subject: [PATCH] Cleanup float arithmetic gcc warning. --- lib/report/report.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/report/report.c b/lib/report/report.c index 9988be3f9..9ea30c352 100644 --- a/lib/report/report.c +++ b/lib/report/report.c @@ -1049,7 +1049,7 @@ static int _snpercent_disp(struct dm_report *rh __attribute((unused)), struct dm return 0; } - *sortval = snap_percent * UINT64_C(1000); + *sortval = (uint64_t)(snap_percent * 1000.f); dm_report_field_set_value(field, repstr, sortval); return 1; @@ -1091,7 +1091,7 @@ static int _copypercent_disp(struct dm_report *rh __attribute((unused)), return 0; } - *sortval = percent * UINT64_C(1000); + *sortval = (uint64_t)(percent * 1000.f); dm_report_field_set_value(field, repstr, sortval); return 1;