X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=ztest%2Fztest.c;h=88e0a21096a55ff2ec009db5714ca79bb0605142;hb=33054ee1b9de573a3de49e09267b1bfb912c5a0c;hp=c4e7b49685a3556e7feec5339c18c4ab2c44f84b;hpb=b8b750a84e0c9f7253d210f9604e385bd84a7569;p=yaz-moved-to-github.git diff --git a/ztest/ztest.c b/ztest/ztest.c index c4e7b49..88e0a21 100644 --- a/ztest/ztest.c +++ b/ztest/ztest.c @@ -1,11 +1,14 @@ /* This file is part of the YAZ toolkit. - * Copyright (C) 1995-2010 Index Data + * Copyright (C) 1995-2011 Index Data * See the file LICENSE for details. */ - /** \file * \brief yaz-ztest Generic Frontend Server */ +#if HAVE_CONFIG_H +#include +#endif + #include #include @@ -210,8 +213,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 }