Prevent undefined behaviour with thread_safe_gl enabled.

CreateOffscreenContext already calls ClearCurrent. When it is done twice,
the global GL mutex is unlocked a second time, and undefined behavour
happens. In this particular case, a deadlock occured; unlocking the already
unlocked mutex locked it.
This commit is contained in:
sephiroth99 2016-02-11 23:50:11 -05:00
parent 205f64eb8b
commit a442bb50b4
1 changed files with 0 additions and 1 deletions

View File

@ -59,7 +59,6 @@ X_STATUS GraphicsSystem::Setup(cpu::Processor* processor,
// It's shared with the display context so that we can resolve framebuffers
// from it.
processor_context = provider()->CreateOffscreenContext();
processor_context->ClearCurrent();
});
if (!processor_context) {
xe::FatalError(