RenderKit / ospray

An Open, Scalable, Portable, Ray Tracing Based Rendering Engine for High-Fidelity Visualization
http://ospray.org
Apache License 2.0
1.01k stars 182 forks source link

ospInit without ospShutdown results in EXC_BAD_ACCESS #441

Closed StasJ closed 3 years ago

StasJ commented 4 years ago

The following code will crash

ospInit(argc, (const char **)argv);
exit(0);
johguenther commented 3 years ago

Well, ospShutdown() call ensures that the current device is cleaned up appropriately. Due to static object allocation having non-deterministic ordering it should be used to avoid the crash on exit.