Luncher/Pager Gadgets: Fix coverity warnings for CID 1365330, CID 1365332 and CID 1365405

This commit also fixes T4831
This commit is contained in:
Stephen okra Houston 2016-11-07 09:35:34 -06:00
parent be154b60c8
commit ec326b304b
2 changed files with 16 additions and 9 deletions

View File

@ -1217,7 +1217,7 @@ _bar_cb_exec_client_prop(void *data EINA_UNUSED, int type EINA_UNUSED, E_Event_C
{
if (has_desktop)
ic->execs = eina_list_remove(ic->execs, ev->ec->exe_inst);
if (ev->ec)
else
ic->clients = eina_list_remove(ic->clients, ev->ec);
if (!eina_list_count(ic->execs) && !eina_list_count(ic->clients))
{
@ -1786,12 +1786,15 @@ _bar_recalculate_job(void *data)
{
Instance *inst = data;
if (inst && inst->o_icon_con)
if (inst)
{
_bar_empty(inst);
_bar_fill(inst);
if (inst->o_icon_con)
{
_bar_empty(inst);
_bar_fill(inst);
}
inst->recalc_job = NULL;
}
inst->recalc_job = NULL;
}
EINTERN void

View File

@ -905,6 +905,9 @@ _pager_cb_event_desk_show(void *data EINA_UNUSED, int type EINA_UNUSED, void *ev
Pager_Popup *pp;
Pager_Desk *pd;
if (!eina_list_count(pagers))
return ECORE_CALLBACK_PASS_ON;
EINA_LIST_FOREACH(pagers, l, p)
{
if (p->zone != ev->desk->zone) continue;
@ -964,6 +967,7 @@ static Eina_Bool
_pager_cb_event_client_urgent_change(void *data EINA_UNUSED, int type EINA_UNUSED, E_Event_Client_Property *ev)
{
if (!(ev->property & E_CLIENT_PROPERTY_URGENCY)) return ECORE_CALLBACK_RENEW;
if (!eina_list_count(pagers)) return ECORE_CALLBACK_RENEW;
if (pager_config->popup_urgent && (!e_client_util_desk_visible(ev->ec, e_desk_current_get(ev->ec->zone))) &&
(pager_config->popup_urgent_focus ||
@ -1360,10 +1364,10 @@ _pager_drop_cb_drop(void *data, const char *type, void *event_info)
if (max) e_client_maximize(ec, max);
if (fullscreen) e_client_fullscreen(ec, fs);
}
}
EINA_LIST_FOREACH(pd->pager->desks, l, pdd)
{
edje_object_signal_emit(pdd->o_desk, "e,action,drag,out", "e");
EINA_LIST_FOREACH(pd->pager->desks, l, pdd)
{
edje_object_signal_emit(pdd->o_desk, "e,action,drag,out", "e");
}
}
}