forked from enlightenment/efl
elm: Fix potential null point dereferences.
Summary: If every assigning logics to enginelist is not performed some how, system will crash because the first parameter of strcmp is null. Test Plan: N/A Reviewers: Hermet Reviewed By: Hermet Subscribers: cedric, Hermet, raster, jpeg Differential Revision: https://phab.enlightenment.org/D4149
This commit is contained in:
parent
9873358f68
commit
19b2915863
|
@ -4210,10 +4210,8 @@ _elm_win_finalize_internal(Eo *obj, Efl_Ui_Win_Data *sd, const char *name, Elm_W
|
|||
#endif
|
||||
}
|
||||
}
|
||||
enginelist[p++] = NULL;
|
||||
for (i = 0; i < 30; i++)
|
||||
for (i = 0; i < p; i++)
|
||||
{
|
||||
if ((i > 0) && (!enginelist[i])) break;
|
||||
if (!strcmp(enginelist[i], ELM_SOFTWARE_X11))
|
||||
tmp_sd.ee = ecore_evas_software_x11_new(NULL, 0, 0, 0, 1, 1);
|
||||
else if (!strcmp(enginelist[i], ELM_OPENGL_X11))
|
||||
|
|
Loading…
Reference in New Issue