[tracker] tracker-miner-fs: Trigger reindex of files/directories on IndexFiles
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker] tracker-miner-fs: Trigger reindex of files/directories on IndexFiles
- Date: Sat, 28 May 2016 22:16:04 +0000 (UTC)
commit 5750114229d94d3e0ec189ca39ba4e7ab60b99ed
Author: Carlos Garnacho <carlosg gnome org>
Date: Wed May 25 00:57:23 2016 +0200
tracker-miner-fs: Trigger reindex of files/directories on IndexFiles
If the file was already contained in an indexed directory, the IndexFile
was ignored. Actually cause a reindexing so we can trigger rechecks after
deleting the data.
src/miners/fs/tracker-miner-files-index.c | 7 ++++++-
1 files changed, 6 insertions(+), 1 deletions(-)
---
diff --git a/src/miners/fs/tracker-miner-files-index.c b/src/miners/fs/tracker-miner-files-index.c
index eb309ae..ea995f0 100644
--- a/src/miners/fs/tracker-miner-files-index.c
+++ b/src/miners/fs/tracker-miner-files-index.c
@@ -391,13 +391,18 @@ handle_method_call_index_file (TrackerMinerFilesIndex *miner,
* directory (nor add a watch if we're positive it comes from
* config).
*/
- if (!root || !(flags & TRACKER_DIRECTORY_FLAG_RECURSE)) {
+ if (!root ||
+ (!(flags & TRACKER_DIRECTORY_FLAG_RECURSE) &&
+ !g_file_equal (root, file) &&
+ !g_file_has_parent (file, root))) {
tracker_indexing_tree_add (indexing_tree, file,
TRACKER_DIRECTORY_FLAG_RECURSE |
TRACKER_DIRECTORY_FLAG_PRIORITY |
TRACKER_DIRECTORY_FLAG_CHECK_MTIME |
TRACKER_DIRECTORY_FLAG_MONITOR);
needs_watch = TRUE;
+ } else {
+ tracker_indexing_tree_notify_update (indexing_tree, file, TRUE);
}
if (watch_source && (is_watched || needs_watch)) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]