Re #720 Fixed warnings with MinGW Gcc 4.7.1

git-svn-id: https://svn.code.sf.net/p/speed-dreams/code/trunk@5043 30fe4595-0a0c-4342-8851-515496e4dcbd

Former-commit-id: b286fc821a81a4aeb3b7e8a1ce9b6ca597fcc3b2
Former-commit-id: c4b48207f587450ed196d7a801fc3e85d9640cae
This commit is contained in:
pouillot 2012-11-11 19:38:09 +00:00
parent a3472f3e04
commit c24d439c0a
2 changed files with 4 additions and 2 deletions

View file

@ -110,7 +110,7 @@ bool GfFileCopy(const char* pszSrcName, const char* pszTgtName)
// TODO: Use GfFileGetDirName // TODO: Use GfFileGetDirName
strncpy(buf, pszTgtName, strlen(pszTgtName)+1); strncpy(buf, pszTgtName, strlen(pszTgtName)+1);
#ifdef WIN32 #ifdef WIN32
for (int i = 0; i < maxBufSize && buf[i] != '\0'; i++) for (size_t i = 0; i < maxBufSize && buf[i] != '\0'; i++)
if (buf[i] == '\\') if (buf[i] == '\\')
buf[i] = '/'; buf[i] = '/';
#endif #endif

View file

@ -20,12 +20,14 @@
#ifndef NETWORK_H #ifndef NETWORK_H
#define NETWORK_H #define NETWORK_H
#ifdef _MSC_VER
#pragma warning (disable: 4251)
#endif
#ifdef _WIN32 #ifdef _WIN32
#ifndef DLLEXPORT #ifndef DLLEXPORT
#define DLLEXPORT __declspec(dllexport) #define DLLEXPORT __declspec(dllexport)
#endif #endif
#pragma warning (disable: 4251)
#else #else
#ifndef DLLEXPORT #ifndef DLLEXPORT
#define DLLEXPORT #define DLLEXPORT