summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Blumenkrantz <michael.blumenkrantz@gmail.com>2012-06-12 07:44:27 +0000
committerMike Blumenkrantz <michael.blumenkrantz@gmail.com>2012-06-12 07:44:27 +0000
commitd7190117c9b9afc41f81c633f4a4148b20fccafd (patch)
tree881cdb6f5e4e2de77f46ee46ebf79871d8564e97
parentb4f84d4edccf3d1aafc56e70b736a1b3a6531fd3 (diff)
backport previous commitecore-1.1
SVN revision: 71986
-rw-r--r--ChangeLog5
-rw-r--r--src/lib/ecore_file/ecore_file_monitor_inotify.c4
2 files changed, 7 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index b16b0578..7482fbce 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -406,3 +406,8 @@
4062012-06-07 Mike Blumenkrantz 4062012-06-07 Mike Blumenkrantz
407 407
408 * 1.1.1 release 408 * 1.1.1 release
409
4102012-06-12 Mike Blumenkrantz
411
412 * Fixed bug in ecore-file monitoring with inotify where watching a file
413 that was deleted broke the world.
diff --git a/src/lib/ecore_file/ecore_file_monitor_inotify.c b/src/lib/ecore_file/ecore_file_monitor_inotify.c
index efdd8c2b..30226d3a 100644
--- a/src/lib/ecore_file/ecore_file_monitor_inotify.c
+++ b/src/lib/ecore_file/ecore_file_monitor_inotify.c
@@ -274,7 +274,7 @@ _ecore_file_monitor_inotify_events(Ecore_File_Monitor *em, char *file, int mask)
274 * else delete it */ 274 * else delete it */
275 if (ecore_file_exists(em->path)) 275 if (ecore_file_exists(em->path))
276 { 276 {
277 if (!_ecore_file_monitor_inotify_monitor(em, em->path)) 277 if (_ecore_file_monitor_inotify_monitor(em, em->path))
278 em->func(em->data, em, ECORE_FILE_EVENT_DELETED_SELF, em->path); 278 em->func(em->data, em, ECORE_FILE_EVENT_DELETED_SELF, em->path);
279 } 279 }
280 else 280 else
@@ -301,7 +301,7 @@ _ecore_file_monitor_inotify_monitor(Ecore_File_Monitor *em, const char *path)
301 inotify_add_watch(ecore_main_fd_handler_fd_get(_fdh), path, mask); 301 inotify_add_watch(ecore_main_fd_handler_fd_get(_fdh), path, mask);
302 if (ECORE_FILE_MONITOR_INOTIFY(em)->wd < 0) 302 if (ECORE_FILE_MONITOR_INOTIFY(em)->wd < 0)
303 { 303 {
304 ERR("inotify_add_watch error"); 304 INF("inotify_add_watch failed, file was deleted");
305 ecore_file_monitor_inotify_del(em); 305 ecore_file_monitor_inotify_del(em);
306 return 0; 306 return 0;
307 } 307 }