16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-18 01:59:19 +02:00

throw bad alloc on opengl oom

This commit is contained in:
milek7
2018-08-03 22:38:23 +02:00
parent af0e193bde
commit f0b4f42128
3 changed files with 3 additions and 7 deletions

View File

@@ -36,12 +36,12 @@ int main( int argc, char *argv[] )
result = Application.run();
}
Application.exit();
std::_Exit(0); // skip destructors, there are ordering errors which causes segfaults
return result;
}
catch( std::bad_alloc const &Error )
{
ErrorLog( "Critical error, memory allocation failure: " + std::string( Error.what() ) );
return -1;
}
LogsFlush();
std::_Exit(0); // skip destructors, there are ordering errors which causes segfaults
}