On 25/03/15 14:11, Cedric BAIL wrote: > Eo is tricky here and not obvious. You need to use eo_isa in fact as data > scope can return invalid pointer different from null... >
It's significantly slower to check that. There's actually a define that that lets you enable that kind of checking. However, given the fact that most calls are from a safe area (inside an eo do func), it's just not worth the extra slowdown associated with it. Maybe we should create an eo_do_safe_get(), or alternatively, make this one the safe slow one, and have eo_data_unsafe_get(). Not sure which. Thoughts? -- Tom. > Le 24 mars 2015 22:45, "ChunEon Park" <her...@hermet.pe.kr> a écrit : >> >> hermet pushed a commit to branch master. >> >> > http://git.enlightenment.org/core/efl.git/commit/?id=e56548aa33000561f1970abd48bfc03f05019415 >> >> commit e56548aa33000561f1970abd48bfc03f05019415 >> Author: ChunEon Park <chuneon.p...@samsung.com> >> Date: Wed Mar 25 14:42:44 2015 +0900 >> >> ecore_idler: + null check. >> >> like timer, animator we do check the idler validation >> and prevert crash there just in user misusage case. >> >> @fix >> --- >> src/lib/ecore/ecore_idler.c | 1 + >> 1 file changed, 1 insertion(+) >> >> diff --git a/src/lib/ecore/ecore_idler.c b/src/lib/ecore/ecore_idler.c >> index 5faed54..a874717 100644 >> --- a/src/lib/ecore/ecore_idler.c >> +++ b/src/lib/ecore/ecore_idler.c >> @@ -87,6 +87,7 @@ static void * >> _ecore_idler_del(Ecore_Idler *obj) >> { >> Ecore_Idler_Data *idler = eo_data_scope_get(obj, MY_CLASS); >> + EINA_SAFETY_ON_NULL_RETURN_VAL(idler, NULL); >> EINA_SAFETY_ON_TRUE_RETURN_VAL(idler->delete_me, NULL); >> idler->delete_me = 1; >> idlers_delete_me = 1; >> >> -- >> >> >> > ------------------------------------------------------------------------------ > Dive into the World of Parallel Programming The Go Parallel Website, sponsored > by Intel and developed in partnership with Slashdot Media, is your hub for all > things parallel software development, from weekly thought leadership blogs to > news, videos, case studies, tutorials and more. Take a look and join the > conversation now. http://goparallel.sourceforge.net/ > _______________________________________________ > enlightenment-devel mailing list > enlightenment-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel > ------------------------------------------------------------------------------ Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/ _______________________________________________ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel