ecore-file: do not emit events when an inotify watch is removed

???????????????????????????????????????????????????????????????????????????????

@fix
This commit is contained in:
Mike Blumenkrantz 2017-10-03 13:33:14 -04:00
parent 31ef275388
commit 11e92cdc86
1 changed files with 3 additions and 11 deletions

View File

@ -262,17 +262,9 @@ _ecore_file_monitor_inotify_events(Ecore_File_Monitor *em, char *file, int mask)
em->func(em->data, em, ECORE_FILE_EVENT_DELETED_SELF, em->path); em->func(em->data, em, ECORE_FILE_EVENT_DELETED_SELF, em->path);
} }
if (mask & IN_IGNORED) if (mask & IN_IGNORED)
{ /* The watch is removed. If the file name still exists monitor the new one,
/* The watch is removed. If the file name still exists monitor the new one, * else delete it */
* else delete it */ _ecore_file_monitor_inotify_monitor(em, em->path);
if (ecore_file_exists(em->path))
{
if (_ecore_file_monitor_inotify_monitor(em, em->path))
em->func(em->data, em, ECORE_FILE_EVENT_DELETED_SELF, em->path);
}
else
em->func(em->data, em, ECORE_FILE_EVENT_DELETED_SELF, em->path);
}
} }
static int static int