Răsfoiți Sursa

Fix Mac build issues (clang 6.0 compiling x86_64)

Alexander Gessler 10 ani în urmă
părinte
comite
f435712273
2 a modificat fișierele cu 3 adăugiri și 2 ștergeri
  1. 1 0
      code/ObjFileMtlImporter.cpp
  2. 2 2
      code/Q3BSPZipArchive.cpp

+ 1 - 0
code/ObjFileMtlImporter.cpp

@@ -42,6 +42,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 #ifndef ASSIMP_BUILD_NO_OBJ_IMPORTER
 
+#include <stdlib.h>
 #include "ObjFileMtlImporter.h"
 #include "ObjTools.h"
 #include "ObjFileData.h"

+ 2 - 2
code/Q3BSPZipArchive.cpp

@@ -140,11 +140,11 @@ zlib_filefunc_def IOSystem2Unzip::get(IOSystem* pIOHandler) {
 ZipFile::ZipFile(size_t size) : m_Size(size) {
 	ai_assert(m_Size != 0);
 
-	m_Buffer = std::malloc(m_Size);
+	m_Buffer = malloc(m_Size);
 }
 	
 ZipFile::~ZipFile() {
-	std::free(m_Buffer);
+	free(m_Buffer);
 	m_Buffer = NULL;
 }