Whitelist the compilers that need malloc.h for alloca

This commit is contained in:
Sean Barrett 2016-08-27 12:09:01 -07:00
parent 4806aca183
commit f4938bfa4d

View File

@ -553,12 +553,12 @@ enum STBVorbisError
#include <string.h> #include <string.h>
#include <assert.h> #include <assert.h>
#include <math.h> #include <math.h>
#if !(defined(__APPLE__) || defined(MACOSX) || defined(macintosh) || defined(Macintosh)) #ifdef _MSC_VER
#include <malloc.h> #include <malloc.h>
#endif
#if defined(__linux__) || defined(__linux) || defined(__EMSCRIPTEN__) #if defined(__linux__) || defined(__linux) || defined(__EMSCRIPTEN__)
#include <alloca.h> #include <alloca.h>
#endif #endif
#endif
#else // STB_VORBIS_NO_CRT #else // STB_VORBIS_NO_CRT
#define NULL 0 #define NULL 0
#define malloc(s) 0 #define malloc(s) 0