summaryrefslogtreecommitdiff
path: root/thirdparty/libwebsockets/win32helpers/gettimeofday.h
blob: 33e7a750fe41478c2a6f7af0bd6060c0ea60cee9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#ifndef _GET_TIME_OF_DAY_H
#define _GET_TIME_OF_DAY_H

#include <time.h>

#if defined(_MSC_VER) || defined(_MSC_EXTENSIONS)
  #define DELTA_EPOCH_IN_MICROSECS  11644473600000000Ui64
#else
  #define DELTA_EPOCH_IN_MICROSECS  11644473600000000ULL
#endif

#ifdef LWS_MINGW_SUPPORT
  #include <winsock2.h>
#endif

#ifndef _TIMEZONE_DEFINED 
struct timezone 
{
  int  tz_minuteswest; /* minutes W of Greenwich */
  int  tz_dsttime;     /* type of dst correction */
};

#endif

int gettimeofday(struct timeval *tv, struct timezone *tz);

#endif