Avoid using gettimeofday().

This commit is contained in:
Hans Leidekker 2004-10-18 19:38:41 +00:00 committed by Alexandre Julliard
parent 96d6966baa
commit 6e8f4f3c69
1 changed files with 3 additions and 3 deletions

View File

@ -181,7 +181,7 @@ static void create_registry_keys( const SYSTEM_INFO *info )
*/
BOOL WINAPI QueryPerformanceCounter(PLARGE_INTEGER counter)
{
struct timeval tv;
LARGE_INTEGER time;
#if defined(__i386__) && defined(__GNUC__)
if (IsProcessorFeaturePresent( PF_RDTSC_INSTRUCTION_AVAILABLE )) {
@ -194,8 +194,8 @@ BOOL WINAPI QueryPerformanceCounter(PLARGE_INTEGER counter)
#endif
/* fall back to generic routine (ie, for i386, i486) */
gettimeofday( &tv, NULL );
counter->QuadPart = (LONGLONG)tv.tv_usec + (LONGLONG)tv.tv_sec * 1000000;
NtQuerySystemTime( &time );
counter->QuadPart = time.QuadPart;
return TRUE;
}