Don't segfault if null device creation failed
This commit is contained in:
parent
e3b3a369d0
commit
8e29c189c4
@ -1647,6 +1647,12 @@ void initRest()
|
|||||||
stk_config->load(file_manager->getAsset("stk_config.xml"));
|
stk_config->load(file_manager->getAsset("stk_config.xml"));
|
||||||
|
|
||||||
irr_driver = new IrrDriver();
|
irr_driver = new IrrDriver();
|
||||||
|
|
||||||
|
if (irr_driver->getDevice() == NULL)
|
||||||
|
{
|
||||||
|
Log::fatal("main", "Couldn't initialise irrlicht device. Quitting.\n");
|
||||||
|
}
|
||||||
|
|
||||||
StkTime::init(); // grabs the timer object from the irrlicht device
|
StkTime::init(); // grabs the timer object from the irrlicht device
|
||||||
|
|
||||||
// Now create the actual non-null device in the irrlicht driver
|
// Now create the actual non-null device in the irrlicht driver
|
||||||
|
Loading…
Reference in New Issue
Block a user