From 9629dc2f718a92b415653d494527ee2c3b0640a2 Mon Sep 17 00:00:00 2001 From: Adam Dickmeiss Date: Mon, 11 Oct 2010 12:50:47 +0200 Subject: [PATCH] Use casts rather than floor(3) --- ztest/ztest.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ztest/ztest.c b/ztest/ztest.c index c4e7b49..2ef8921 100644 --- a/ztest/ztest.c +++ b/ztest/ztest.c @@ -210,8 +210,8 @@ static void ztest_sleep(double d) Sleep( (DWORD) (d * 1000)); #else struct timeval tv; - tv.tv_sec = floor(d); - tv.tv_usec = (d - floor(d)) * 1000000; + tv.tv_sec = d; + tv.tv_usec = (d - (long) d) * 1000000; select(0, 0, 0, 0, &tv); #endif } -- 1.7.10.4