evas filters: Fix rare crash with async render
Reported by bu5hm4n @fix (backport will look slightly different)
This commit is contained in:
parent
3c92b32c13
commit
03b0e23137
|
@ -130,6 +130,7 @@ _filter_end_sync(Evas_Filter_Context *ctx, Evas_Object_Protected_Data *obj,
|
|||
}
|
||||
|
||||
FCOW_WRITE(pd, context, ctx);
|
||||
efl_unref(eo_obj);
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -449,16 +450,9 @@ evas_filter_object_render(Eo *eo_obj, Evas_Object_Protected_Data *obj,
|
|||
FCOW_END(fcow, pd);
|
||||
|
||||
// Run the filter now (maybe async)
|
||||
efl_ref(eo_obj);
|
||||
ok = evas_filter_context_run(filter);
|
||||
if (!ok)
|
||||
{
|
||||
ERR("Filter program failed to run!");
|
||||
evas_filter_context_destroy(filter);
|
||||
fcow = FCOW_BEGIN(pd);
|
||||
fcow->context = NULL;
|
||||
fcow->invalid = EINA_TRUE;
|
||||
FCOW_END(fcow, pd);
|
||||
}
|
||||
if (!ok) ERR("Filter program failed to run!");
|
||||
|
||||
return ok;
|
||||
}
|
||||
|
|
|
@ -1880,8 +1880,6 @@ _filter_obscured_region_calc(Evas_Filter_Context *ctx)
|
|||
Eina_Bool
|
||||
evas_filter_context_run(Evas_Filter_Context *ctx)
|
||||
{
|
||||
EINA_SAFETY_ON_NULL_RETURN_VAL(ctx, EINA_FALSE);
|
||||
|
||||
_filter_obscured_region_calc(ctx);
|
||||
|
||||
ctx->run_count++;
|
||||
|
|
Loading…
Reference in New Issue