Don't use EGLRenderer if not built with SDL 2.0.10+
This commit is contained in:
parent
eb9e1f81d4
commit
eb9d54465c
1 changed files with 10 additions and 0 deletions
|
|
@ -182,6 +182,16 @@ bool EGLRenderer::initialize(PDECODER_PARAMETERS params)
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// It's not safe to attempt to opportunistically create a GLES2
|
||||||
|
// renderer prior to 2.0.10. If GLES2 isn't available, SDL will
|
||||||
|
// attempt to dereference a null pointer and crash Moonlight.
|
||||||
|
// https://bugzilla.libsdl.org/show_bug.cgi?id=4350
|
||||||
|
// https://hg.libsdl.org/SDL/rev/84618d571795
|
||||||
|
if (!SDL_VERSION_ATLEAST(2, 0, 10)) {
|
||||||
|
EGL_LOG(Error, "Not supported until SDL 2.0.10");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Create a dummy renderer in order to craft an accelerated SDL Window.
|
* Create a dummy renderer in order to craft an accelerated SDL Window.
|
||||||
* Request opengl ES 3.0 context, otherwise it will SIGSEGV
|
* Request opengl ES 3.0 context, otherwise it will SIGSEGV
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue