From 6bb053f46101e659c4f3a877bf8d17ad37a23225 Mon Sep 17 00:00:00 2001 From: Alan Coopersmith Date: Thu, 8 Dec 2022 13:26:00 -0800 Subject: Remove unnecessary downcast of double to float The printf family always takes double arguments, not float. Clears clang warning of: xdpyinfo.c:767:5: warning: implicit conversion increases floating-point precision: 'float' to 'double' [-Wdouble-promotion] (float)dotclock/1000.0, ^~~~~~~~~~~~~~~~ Signed-off-by: Alan Coopersmith --- xdpyinfo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'xdpyinfo.c') diff --git a/xdpyinfo.c b/xdpyinfo.c index 6c2c4e3..06681b9 100644 --- a/xdpyinfo.c +++ b/xdpyinfo.c @@ -764,7 +764,7 @@ print_XF86VidMode_modeline( unsigned int flags) { printf(" %6.2f %4d %4d %4d %4d %4d %4d %4d %4d ", - (float)dotclock/1000.0, + dotclock/1000.0, hdisplay, hsyncstart, hsyncend, htotal, vdisplay, vsyncstart, vsyncend, vtotal); if (flags & V_PHSYNC) printf(" +hsync"); -- cgit v1.2.3