Author: Pekka Riikonen <priikone@silcnet.org>
- Copyright (C) 2001 - 2005 Pekka Riikonen
+ Copyright (C) 2001 - 2006 Pekka Riikonen
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; version 2 of the License.
-
+
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
const BYTE DWLEN = sizeof(DWORD) * 8;
/* Return current time in struct timeval. Code ripped from some xntp
- implementation on http://src.openresources.com. */
+ implementation. */
int silc_gettimeofday(struct timeval *tv)
{
FILETIME ft;
__int64 msec;
-
+
GetSystemTimeAsFileTime(&ft);
msec = (__int64) ft.dwHighDateTime << DWLEN | ft.dwLowDateTime;
msec = (msec - FILETIME_1970) / 10;