summaryrefslogtreecommitdiffstats
path: root/osdep/gettimeofday.c
blob: 860eb388e7bcef0b79c0a66684c2d52cd71b0b27 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
#include "config.h"

#ifndef HAVE_GETTIMEOFDAY
#include <sys/time.h>
#include <sys/timeb.h>
void gettimeofday(struct timeval* t,void* timezone)
{       struct timeb timebuffer;
        ftime( &timebuffer );
        t->tv_sec=timebuffer.time;
        t->tv_usec=1000*timebuffer.millitm;
}
#endif