Don't try to go out of bounds. Still crashes without the Framebuffer.cpp edit, though..

This commit is contained in:
The Dax 2013-10-12 00:33:03 -04:00
parent 8195804daa
commit 71087b41a2

View file

@ -1463,7 +1463,7 @@ namespace MainWindow
// The Menu ID is contained in wParam, so subtract
// ID_SHADERS_BASE and an additional 1 off it.
index = (wParam - ID_SHADERS_BASE - 1);
if (index >= 0) {
if (index >= 0 && index < availableShaders.size()) {
g_Config.sPostShaderName = availableShaders[index];
if (gpu)