Merge pull request #352 from gheskett/develop/mingw-custom-audio-fix

Fix custom audio files not compiling under MinGW (in case it ever matters)
This commit is contained in:
Gregory Heskett
2022-03-18 12:47:54 -05:00
committed by GitHub

View File

@@ -8243,7 +8243,7 @@ File *File::open(const char *path, File::AccessMode mode)
flags = O_RDONLY;
else if (mode == WriteAccess)
flags = O_CREAT | O_WRONLY | O_TRUNC;
#if defined(WIN32) || defined(__CYGWIN__)
#if defined(WIN32) || defined(__CYGWIN__) || defined(__MINGW32__) || defined(__MINGW64__)
flags |= O_BINARY;
#endif
int fd = ::open(path, flags, 0666);