From a482f385812249886109b4ccace070cef7fe3671 Mon Sep 17 00:00:00 2001 From: Andreas Mohr Date: Sat, 27 Feb 2016 23:53:15 +0000 Subject: [PATCH] Cleanup -Wfloat-conversion warning. Signed-off-by: Andreas Mohr Signed-off-by: Andrew Borodin --- lib/widget/wtools.c | 2 +- src/filemanager/filegui.c | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/widget/wtools.c b/lib/widget/wtools.c index 21727a1e5..c3c1284c8 100644 --- a/lib/widget/wtools.c +++ b/lib/widget/wtools.c @@ -588,7 +588,7 @@ status_msg_init (status_msg_t * sm, const char *title, double delay, status_msg_ sm->dlg = dlg_create (TRUE, 0, 0, 7, min (max (40, COLS / 2), COLS), dialog_colors, NULL, NULL, NULL, title, DLG_CENTER); sm->start = start; - sm->delay = delay * G_USEC_PER_SEC; + sm->delay = (guint64) (delay * G_USEC_PER_SEC); sm->block = FALSE; sm->init = init_cb; diff --git a/src/filemanager/filegui.c b/src/filemanager/filegui.c index 02089b2d7..58094540a 100644 --- a/src/filemanager/filegui.c +++ b/src/filemanager/filegui.c @@ -343,9 +343,9 @@ static void file_frmt_time (char *buffer, double eta_secs) { int eta_hours, eta_mins, eta_s; - eta_hours = eta_secs / (60 * 60); - eta_mins = (eta_secs - (eta_hours * 60 * 60)) / 60; - eta_s = eta_secs - (eta_hours * 60 * 60 + eta_mins * 60); + eta_hours = (int) (eta_secs / (60 * 60)); + eta_mins = (int) ((eta_secs - (eta_hours * 60 * 60)) / 60); + eta_s = (int) (eta_secs - (eta_hours * 60 * 60 + eta_mins * 60)); g_snprintf (buffer, BUF_TINY, _("%d:%02d.%02d"), eta_hours, eta_mins, eta_s); }