Commit Graph

17 Commits

Author SHA1 Message Date
Marcel Hollerbach 1eb24301fd efl_io_model: next try to fix this race condition
what is happening is that a file gets announced through eio_model
listing code, at this point of time, the monitor does not yet know about
the file. If the file now gets deleted between the annoncing and the
learning of the file from the monitor, then the file got an ADD event,
but no DEL event. Which is a bug.

With this commit there is a new API which asks the monitor if the file
already has the knowledge about the files existance, or not. A few
monitors like win32 inotify or cocoa do not have context about the file
directly, if the OS is now having the same bug, then we are again in
trouble, however, we canot do anything about that. In the case of kevent
or poll, this asks the context of the monitor if the file is already
there.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D10006
2019-09-19 14:50:42 -07:00
Carsten Haitzler 9149767184 getenv - reduce continually calling getenv for the same vars do once
do it once and remember the result from the first one. drops overhead
for sure by a chunk i actually could see in perf reports like about 1-2%
of cpu...
2019-08-08 23:57:02 +01:00
Mike Blumenkrantz d55fc77cfa eio: remove broken pid-based monitor reset copied from ecore-file
this has no technical basis for existing and should be handled by
individual monitor backends

@fix
2018-02-07 12:12:22 -05:00
Jean-Philippe Andre ff24ac2d6d efl: Reset ecore event types on init
This fixes cycles of init/shutdown/init where ecore event types would
become invalid, since they are now stored in a dynamic array rather than
a statically stored array.

The risk here is that if a module of EFL tends to init/shutdown in a
"normal" scenario then the event type array will grow in a leaking
manner. This could be fixed by resetting those event ID's only when the
loop actually exits (EFL_EVENT_DEL on the main loop). I'm not using
EFL_EVENT_DEL in this patch as this would add too many event callbacks
to the main loop object, which may result in slightly slower event calls
to it, affecting the overall performance.
2017-12-19 11:14:37 +09:00
Cedric BAIL aef1ee96e8 eio: avoid crash during shutdown due to Ecore_Event queue. 2017-03-09 16:17:58 -08:00
Cedric Bail 57226d86ff eio: handle failure due to lack of access right. 2016-07-15 17:07:49 -07:00
Cedric Bail adff89dfc0 eio: make it possible to force fallback monitor for testing purpose. 2016-07-15 17:07:49 -07:00
Felipe Magno de Almeida 22cfae5b8c eio_monitor: Removed unnecessary eio_file_direct_stat
Removed unnecessary asynchronous stat, which could make eio_monitor to
lose events between the monitor creation and stat completion.
2015-04-10 17:23:12 -03:00
Mike Blumenkrantz cc6eed2f86 eio monitors no longer trigger a CRI error during free
@fix
2014-03-21 14:21:04 -04:00
Cedric BAIL be25ab6f85 eio: let's report the path we didn't found. 2014-03-05 11:46:12 +09:00
Cedric BAIL e1e4774306 eio: improve log when monitoring files. 2014-03-05 10:40:55 +09:00
Jean-Philippe Andre 8fdd3992f0 Eio monitor: Fix crash on invalid data access
Fix race condition when touching/changing a (theme) file often.
An Eio_Monitor was marked as "delete_me" but the rename callback
was still called, leading to memory access to already freed
objects.

Test protocol was:
ELM_THEME=~/default.edj elementary_test &
watch touch ~/default.edj
2014-01-14 14:23:05 +09:00
Carsten Haitzler 323f293ab5 eio - protect against posible segv on rename with eio
this MIGHT fix T45 but i can't reproduce to confirm, but reading a
backtrace indicates this could have been the issue. it looks like
there is room for a dangling pointer anyway, so fix.

stable release - cherry-pick me!
2014-01-07 17:49:29 +09:00
Sebastian Dransfeld 336f6ec328 efl: formatting 2013-06-20 13:28:18 +02:00
Mike Blumenkrantz 300ee59f38 eio functions no longer crash when passed NULL and throw errors accordingly
SVN revision: 81668
2012-12-24 09:44:21 +00:00
Hannes Janetzek 55f2e87201 fix crash in eio_monitor_del
SVN revision: 81630
2012-12-22 01:56:10 +00:00
Vincent Torri 81c86b19f6 merge: eio + fix compilation on windows + minor fixes + po files
don't move eio to IN-EFL right now


SVN revision: 80180
2012-12-04 17:40:58 +00:00