From ea0d3059f44c1edc3fd762c5b921e43e535db290 Mon Sep 17 00:00:00 2001 From: Berke Viktor Date: Tue, 30 Oct 2012 22:13:40 +0100 Subject: Eliminate even more warnings and bump warning level to 3 Shouldn't need to go any higher, level 4+ gives insane warnings --- src/common/cfgfiles.c | 1 + src/common/ignore.c | 1 + src/common/plugin.c | 1 + src/common/text.c | 1 + src/common/typedef.h | 14 ++++++++++++++ 5 files changed, 18 insertions(+) (limited to 'src/common') diff --git a/src/common/cfgfiles.c b/src/common/cfgfiles.c index 7e2cd653..168f116e 100644 --- a/src/common/cfgfiles.c +++ b/src/common/cfgfiles.c @@ -29,6 +29,7 @@ #include "fe.h" #include "text.h" #include "hexchatc.h" +#include "typedef.h" #ifdef WIN32 #include diff --git a/src/common/ignore.c b/src/common/ignore.c index caeae06e..49b95c3b 100644 --- a/src/common/ignore.c +++ b/src/common/ignore.c @@ -36,6 +36,7 @@ #include "text.h" #include "util.h" #include "hexchatc.h" +#include "typedef.h" int ignored_ctcp = 0; /* keep a count of all we ignore */ diff --git a/src/common/plugin.c b/src/common/plugin.c index b918ff05..62b83ae1 100644 --- a/src/common/plugin.c +++ b/src/common/plugin.c @@ -44,6 +44,7 @@ typedef struct session hexchat_context; #include "hexchat-plugin.h" #include "plugin.h" +#include "typedef.h" #include "hexchatc.h" diff --git a/src/common/text.c b/src/common/text.c index 7e8da018..01c59704 100644 --- a/src/common/text.c +++ b/src/common/text.c @@ -43,6 +43,7 @@ #include "outbound.h" #include "hexchatc.h" #include "text.h" +#include "typedef.h" #ifdef WIN32 #include #endif diff --git a/src/common/typedef.h b/src/common/typedef.h index b20612ea..daeffcae 100644 --- a/src/common/typedef.h +++ b/src/common/typedef.h @@ -1,3 +1,8 @@ +#ifndef HEXCHAT_TYPEDEF_H +#define HEXCHAT_TYPEDEF_H + +#ifdef WIN32 + #ifndef SSIZE_T_DEFINED #ifdef ssize_t #undef ssize_t @@ -9,3 +14,12 @@ typedef _W64 int ssize_t; #endif #define SSIZE_T_DEFINED #endif + +#ifndef fstat +#define fstat _fstat +#define stat _stat +#endif + +#endif + +#endif -- cgit 1.4.1