diff --git a/src/eepp/system/fileassociation.cpp b/src/eepp/system/fileassociation.cpp index 7eb8ebc31..eb0426606 100644 --- a/src/eepp/system/fileassociation.cpp +++ b/src/eepp/system/fileassociation.cpp @@ -11,6 +11,9 @@ #include #if EE_PLATFORM == EE_PLATFORM_WIN +#ifndef NOMINMAX +#define NOMINMAX +#endif #include #include @@ -653,7 +656,7 @@ bool FileAssociation::setRegisteredExtensions( const std::vector& r const auto supported = normalizeExtensions( supportedExtensions ); const auto requested = normalizeExtensions( registeredExtensions ); std::vector selected; - selected.reserve( std::min( requested.size(), supported.size() ) ); + selected.reserve( (std::min)( requested.size(), supported.size() ) ); std::set_intersection( requested.begin(), requested.end(), supported.begin(), supported.end(), std::back_inserter( selected ) ); #if EE_PLATFORM == EE_PLATFORM_LINUX || EE_PLATFORM == EE_PLATFORM_BSD