Skip to content

Commit 79f68b9

Browse files
committed
Trying to get rid of zlib warnings - again
1 parent a570a4e commit 79f68b9

File tree

4 files changed

+11
-6
lines changed

4 files changed

+11
-6
lines changed

MUSHclient.vcxproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@
7373
<ClCompile>
7474
<Optimization>Disabled</Optimization>
7575
<AdditionalIncludeDirectories>$(SolutionDir);$(SolutionDir)luacom\;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
76-
<PreprocessorDefinitions>_DEBUG;WIN32;_WINDOWS;LUA51;_CRT_SECURE_NO_WARNINGS;_CRT_NON_CONFORMING_SWPRINTFS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
76+
<PreprocessorDefinitions>_DEBUG;WIN32;_WINDOWS;LUA51;_CRT_SECURE_NO_WARNINGS;_CRT_NON_CONFORMING_SWPRINTFS;NO_WARN_MBCS_MFC_DEPRECATION;%(PreprocessorDefinitions)</PreprocessorDefinitions>
7777
<MinimalRebuild>true</MinimalRebuild>
7878
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
7979
<PrecompiledHeader>Use</PrecompiledHeader>
@@ -122,7 +122,7 @@
122122
<Optimization>MaxSpeed</Optimization>
123123
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
124124
<AdditionalIncludeDirectories>$(SolutionDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
125-
<PreprocessorDefinitions>NDEBUG;WIN32;_WINDOWS;ZLIB_DLL;LUA51;_CRT_SECURE_NO_WARNINGS;_CRT_NON_CONFORMING_SWPRINTFS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
125+
<PreprocessorDefinitions>NDEBUG;WIN32;_WINDOWS;ZLIB_DLL;LUA51;_CRT_SECURE_NO_WARNINGS;_CRT_NON_CONFORMING_SWPRINTFS;NO_WARN_MBCS_MFC_DEPRECATION;%(PreprocessorDefinitions)</PreprocessorDefinitions>
126126
<StringPooling>true</StringPooling>
127127
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
128128
<FunctionLevelLinking>true</FunctionLevelLinking>

zlib/gzguts.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,10 @@
3535
# include <io.h>
3636
#endif
3737

38-
#ifdef WINAPI_FAMILY
3938
# define open _open
4039
# define read _read
4140
# define write _write
4241
# define close _close
43-
#endif
4442

4543
#ifdef NO_DEFLATE /* for compatibility with old definition */
4644
# define NO_GZCOMPRESS

zlib/readme.txt

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,5 +50,13 @@ add:
5050
#pragma warning( disable : 4131) // uses old-style declarator
5151
#pragma warning( disable : 4244) // conversion from 'int' to 'unsigned short', possible loss of data
5252
#pragma warning( disable : 4702) // unreachable code
53-
#define WINAPI_FAMILY 1
5453

54+
55+
5. Edit gzguts.h and remove the #ifdef / #endif from these lines:
56+
57+
#ifdef WINAPI_FAMILY
58+
# define open _open
59+
# define read _read
60+
# define write _write
61+
# define close _close
62+
#endif

zlib/zlib.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
#pragma warning( disable : 4131) // uses old-style declarator
44
#pragma warning( disable : 4244) // conversion from 'int' to 'unsigned short', possible loss of data
55
#pragma warning( disable : 4702) // unreachable code
6-
#define WINAPI_FAMILY 1
76

87
/* zlib.h -- interface of the 'zlib' general purpose compression library
98
version 1.2.8, April 28th, 2013

0 commit comments

Comments
 (0)