forked from enlightenment/efl
Remove unneeded code with notnull.cocci script
The notnull.cocci script from Coccinelle finds places where you check if a variable is NULL, but it's known not to be NULL. The check can be safely removed. For example, this code would be caught by notnull: if (!var) return; if (var && var->fld) { ... } It's needless to check again if var is not NULL because if it's in fact NULL, it would have returned on the previous "if". This commit removes all the trivial places where this pattern happens. Another patch will be generated for the more complex cases. SVN revision: 50241
This commit is contained in:
parent
4c02246e5d
commit
6325ab86a3
|
@ -240,7 +240,7 @@ _parent_hide(void *data, Evas *e __UNUSED__, Evas_Object *obj __UNUSED__, void *
|
||||||
{
|
{
|
||||||
Widget_Data *wd = elm_widget_data_get(data);
|
Widget_Data *wd = elm_widget_data_get(data);
|
||||||
if (!wd) return;
|
if (!wd) return;
|
||||||
if (wd) evas_object_hide(wd->cov);
|
evas_object_hide(wd->cov);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
|
Loading…
Reference in New Issue