提交 aa253569 编写于 作者: H HMM@T430s-x64 提交者: Enrico Giordani

[PR] Fix building problems in MSVS2015.

上级 7388b952
......@@ -103,11 +103,20 @@ typedef uint64_t uint_least64_t;
// 7.18.1.3 Fastest minimum-width integer types
typedef int8_t int_fast8_t;
typedef int16_t int_fast16_t;
#if (_MSC_VER <= 1800)
typedef int16_t int_fast16_t;
#else
typedef int int_fast16_t;
#endif
typedef int32_t int_fast32_t;
typedef int64_t int_fast64_t;
typedef uint8_t uint_fast8_t;
typedef uint16_t uint_fast16_t;
#if (_MSC_VER <= 1800)
typedef uint16_t uint_fast16_t;
#else
typedef unsigned int uint_fast16_t;
#endif
typedef uint32_t uint_fast32_t;
typedef uint64_t uint_fast64_t;
......
......@@ -37,7 +37,9 @@
#ifdef _WIN32
#define inline __inline
#define snprintf _snprintf
#if (_MSC_VER <= 1800)
#define snprintf _snprintf
#endif
#endif
/* Lua CJSON assumes the locale is the same for all threads within a
......
......@@ -750,7 +750,9 @@ union luai_Cast { double l_d; long l_l; };
#ifdef _WIN32
#define snprintf _snprintf
#if (_MSC_VER <= 1800)
#define snprintf _snprintf
#endif
#endif
......
......@@ -37,6 +37,7 @@ typedef unsigned long nfds_t;
#include <WinSock2.h>
#include <fcntl.h>
#include <stdio.h>
#include <sys/stat.h>
// Including a version of this file modified to eliminate prototype
// definitions not removed by INCL_WINSOCK_API_PROTOTYPES
......
......@@ -25,6 +25,9 @@
#ifndef WIN32_INTEROP_TIME_H
#define WIN32_INTEROP_TIME_H
#if (_MSC_VER > 1800)
#include <corecrt.h>
#endif
#include <stdint.h>
#define gettimeofday gettimeofday_highres
......
......@@ -1087,7 +1087,7 @@ void freeClientsInAsyncFreeQueue(void);
void asyncCloseClientOnOutputBufferLimitReached(redisClient *c);
int getClientType(redisClient *c);
int getClientTypeByName(char *name);
char *getClientTypeName(int class);
char *getClientTypeName(int IF_WIN32(_class,class));
void flushSlavesOutputBuffers(void);
void disconnectSlaves(void);
int listenToPort(int port, int *fds, int *count);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册