mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-26 08:30:10 +01:00
egl: added null ptr check
This commit is contained in:
parent
cae4444fa1
commit
8a75d10953
1 changed files with 4 additions and 2 deletions
|
|
@ -340,8 +340,10 @@ _eglChooseConfig(_EGLDriver *drv, EGLDisplay dpy, const EGLint *attrib_list,
|
|||
qsort(configList, count, sizeof(_EGLConfig *), _eglCompareConfigs);
|
||||
|
||||
/* copy config handles to output array */
|
||||
for (i = 0; i < count; i++) {
|
||||
configs[i] = configList[i]->Handle;
|
||||
if (configs) {
|
||||
for (i = 0; i < count; i++) {
|
||||
configs[i] = configList[i]->Handle;
|
||||
}
|
||||
}
|
||||
|
||||
free(configList);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue