Skip to content

Commit

Permalink
Merge pull request #283 from nyq/nyq-fix-min-max-conflicts
Browse files Browse the repository at this point in the history
Prevent min/max conflicts between windows.h and std namespace
  • Loading branch information
uroni authored Sep 28, 2023
2 parents 9ae305f + 90a5b2f commit a23a38b
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions miniz_zip.c
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,12 @@ extern "C" {
#if defined(_MSC_VER) || defined(__MINGW64__) || defined(__MINGW32__)

#define WIN32_LEAN_AND_MEAN
#ifndef __cplusplus
#define MICROSOFT_WINDOWS_WINBASE_H_DEFINE_INTERLOCKED_CPLUSPLUS_OVERLOADS 0
#endif
#ifndef NOMINMAX
#define NOMINMAX
#endif
#include <windows.h>

static WCHAR* mz_utf8z_to_widechar(const char* str)
Expand Down

0 comments on commit a23a38b

Please sign in to comment.