From: Marcel Hollerbach Date: Tue, 2 Apr 2019 12:50:48 +0000 (-0400) Subject: eio: ensure that the monitor starts when it is called to X-Git-Tag: accepted/tizen/unified/20190410.002130~40 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7535cb092f5f641ce632c330f94356843eb27911;p=platform%2Fupstream%2Fefl.git eio: ensure that the monitor starts when it is called to Summary: we need to to this here, otherwise we effectfily start the monitor later, which means, we can miss a change in the filesystem. However, this makes things a lot slower. Reviewers: cedric Reviewed By: cedric Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D8526 --- diff --git a/src/lib/eio/eio_monitor_poll.c b/src/lib/eio/eio_monitor_poll.c index 2788aee..55cdff6 100644 --- a/src/lib/eio/eio_monitor_poll.c +++ b/src/lib/eio/eio_monitor_poll.c @@ -196,7 +196,7 @@ _eio_monitor_fallback_heavy_cb(void *data, Ecore_Thread *thread) } cmp->version = backend->version; - if (ecore_thread_check(thread)) break; + if (thread && ecore_thread_check(thread)) break; } if (it) eina_iterator_free(it); @@ -346,6 +346,9 @@ eio_monitor_fallback_add(Eio_Monitor *monitor) backend->parent = monitor; monitor->backend = backend; monitor->fallback = EINA_TRUE; + + //ensure this is initialized here + _eio_monitor_fallback_heavy_cb(backend, NULL); backend->work = ecore_thread_run(_eio_monitor_fallback_heavy_cb, _eio_monitor_fallback_end_cb, _eio_monitor_fallback_cancel_cb,