Win fixes
This commit is contained in:
@@ -59,8 +59,10 @@
|
||||
#define IPPROTO_SCTP 132
|
||||
#endif
|
||||
|
||||
#if defined(__MINGW32__) || defined(__MINGW64__)
|
||||
#undef gettimeofday
|
||||
#define gettimeofday mingw_gettimeofday
|
||||
#endif
|
||||
|
||||
extern char* strsep(char **sp, char *sep);
|
||||
|
||||
@@ -93,11 +95,6 @@ extern unsigned long waitForNextEvent(unsigned long ulDelay /* ms */);
|
||||
#define strtok_r strtok_s
|
||||
#define timegm _mkgmtime
|
||||
|
||||
static inline struct tm * localtime_r(const time_t *timep, struct tm * result)
|
||||
{
|
||||
struct tm *timeinfo;
|
||||
timeinfo = localtime(timep);
|
||||
return timeinfo;
|
||||
}
|
||||
extern struct tm* localtime_r(const time_t* timep, struct tm* r);
|
||||
|
||||
#endif /* __NDPI_WIN32_H__ */
|
||||
|
||||
@@ -70,7 +70,7 @@
|
||||
|
||||
/* **************************************************** */
|
||||
|
||||
static ssize_t ndpi_community_id_buf_copy(u_int8_t * const dst, const void * const src, ssize_t len) {
|
||||
static u_int16_t ndpi_community_id_buf_copy(u_int8_t * const dst, const void * const src, u_int16_t len) {
|
||||
if(src)
|
||||
memcpy(dst, src, len);
|
||||
else
|
||||
|
||||
@@ -1802,3 +1802,4 @@ u_int32_t ndpi_quick_16_byte_hash(u_int8_t *in_16_bytes_long) {
|
||||
return((u_int32_t)a);
|
||||
}
|
||||
|
||||
/* ******************************************************************** */
|
||||
|
||||
Reference in New Issue
Block a user