efl_ui_selection_manager: Fix unchecked return value

This patch fixes an issue where the return value from ecore_x_init is
not checked. If we fail to initialize ecore_x, then we should print
out an error and get out.

Fixes Coverity CID1399092

@fix

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D8312
This commit is contained in:
Christopher Michael 2019-03-12 10:11:21 -04:00 committed by Marcel Hollerbach
parent 3cdb7df50b
commit 62d7d8a418
1 changed files with 5 additions and 1 deletions

View File

@ -5179,7 +5179,11 @@ _efl_ui_selection_manager_efl_object_constructor(Eo *obj, Efl_Ui_Selection_Manag
}
if (init_x)
{
ecore_x_init(NULL);
if (!ecore_x_init(NULL))
{
ERR("Could not initialize Ecore_X");
return NULL;
}
}
#endif
#ifdef HAVE_ELEMENTARY_WL2