Fixed indentation

This commit is contained in:
Robert Osfield
2011-03-08 15:31:49 +00:00
parent 42b709a9f4
commit 99aeca003b
3 changed files with 34 additions and 34 deletions

View File

@@ -36,24 +36,24 @@ int gettimeofday(struct timeval* tp, void* tzp) {
LARGE_INTEGER t;
if(QueryPerformanceCounter(&t)) {
/* hardware supports a performance counter */
static int been_here = 0;
static LARGE_INTEGER f;
if( !been_here )
{
been_here = 1;
QueryPerformanceFrequency(&f);
}
tp->tv_sec = t.QuadPart/f.QuadPart;
tp->tv_usec = ((float)t.QuadPart/f.QuadPart*1000*1000)
- (tp->tv_sec*1000*1000);
/* hardware supports a performance counter */
static int been_here = 0;
static LARGE_INTEGER f;
if( !been_here )
{
been_here = 1;
QueryPerformanceFrequency(&f);
}
tp->tv_sec = t.QuadPart/f.QuadPart;
tp->tv_usec = ((float)t.QuadPart/f.QuadPart*1000*1000)
- (tp->tv_sec*1000*1000);
} else {
/* hardware doesn't support a performance counter, so get the
time in a more traditional way. */
DWORD t;
t = timeGetTime();
tp->tv_sec = t / 1000;
tp->tv_usec = t % 1000;
/* hardware doesn't support a performance counter, so get the
time in a more traditional way. */
DWORD t;
t = timeGetTime();
tp->tv_sec = t / 1000;
tp->tv_usec = t % 1000;
}
/* 0 indicates that the call succeeded. */