gsdx ocl: avoid a crash if ocl is selected but not enabled

This commit is contained in:
Gregory Hainaut 2014-12-23 19:39:02 +01:00
parent 767b841fea
commit ee34bd724f
1 changed files with 4 additions and 0 deletions

View File

@ -267,9 +267,13 @@ static int _GSopen(void** dsp, char* title, int renderer, int threads = -1)
case 14: case 15: case 16: case 17:
#ifdef ENABLE_OPENCL
s_gs = new GSRendererCL();
#else
printf("GSdx error: opencl is disabled\n");
#endif
break;
}
if (s_gs == NULL)
return -1;
s_renderer = renderer;
}