Use "wb" when writing binary STL exports, fixes #556.

pull/558/head
Alexander Gessler 2015-05-12 21:51:27 +02:00 committed by Alexander Gessler
parent 7771ce5db2
commit 0fe8e739c3
1 changed files with 1 additions and 1 deletions

View File

@ -75,7 +75,7 @@ void ExportSceneSTLBinary(const char* pFile,IOSystem* pIOSystem, const aiScene*
STLExporter exporter(pFile, pScene, true); STLExporter exporter(pFile, pScene, true);
// we're still here - export successfully completed. Write the file. // we're still here - export successfully completed. Write the file.
boost::scoped_ptr<IOStream> outfile (pIOSystem->Open(pFile,"wt")); boost::scoped_ptr<IOStream> outfile (pIOSystem->Open(pFile,"wb"));
if(outfile == NULL) { if(outfile == NULL) {
throw DeadlyExportError("could not open output .stl file: " + std::string(pFile)); throw DeadlyExportError("could not open output .stl file: " + std::string(pFile));
} }