Commit ec5ae6ae authored by Carlos Garnacho's avatar Carlos Garnacho Committed by Carlos Garnacho

And add back that recurse boolean parameter to the function, looks like

2009-02-11  Carlos Garnacho  <carlos@imendio.com>

        * src/tracker-indexer/tracker-indexer.c (item_move): And add back that
        recurse boolean parameter to the function, looks like commit r2892 to
        tracker-indexer.c wiped out the previous commit.

svn path=/trunk/; revision=2917
parent a04f78a1
2009-02-11 Carlos Garnacho <carlos@imendio.com>
* src/tracker-indexer/tracker-indexer.c (item_move): And add back that
recurse boolean parameter to the function, looks like commit r2892 to
tracker-indexer.c wiped out the previous commit.
2009-02-11 Mikael Ottela <mikael.ottela@ixonos.com>
* data/services/default.service
......
......@@ -208,7 +208,8 @@ static void state_check (TrackerIndexer *indexer);
static void item_remove (TrackerIndexer *indexer,
PathInfo *info,
const gchar *dirname,
const gchar *basename);
const gchar *basename,
gboolean recurse);
static guint signals[LAST_SIGNAL] = { 0, };
......@@ -1775,7 +1776,7 @@ item_move (TrackerIndexer *indexer,
g_message ("Destination file '%s' already existed in database, removing", path);
tracker_file_get_path_and_name (path, &dest_dirname, &dest_basename);
item_remove (indexer, info, dest_dirname, dest_basename);
item_remove (indexer, info, dest_dirname, dest_basename, TRUE);
g_free (dest_dirname);
g_free (dest_basename);
......@@ -1838,7 +1839,8 @@ static void
item_remove (TrackerIndexer *indexer,
PathInfo *info,
const gchar *dirname,
const gchar *basename)
const gchar *basename,
gboolean recurse)
{
TrackerService *service;
TrackerDataMetadata *data_metadata;
......@@ -1945,7 +1947,7 @@ item_remove (TrackerIndexer *indexer,
tracker_data_update_delete_service (service, service_id);
tracker_data_update_delete_all_metadata (service, service_id);
if (strcmp (service_type, "Folders") == 0) {
if (recurse && strcmp (service_type, "Folders") == 0) {
tracker_data_update_delete_service_recursively (service, path);
}
......@@ -2366,7 +2368,11 @@ process_file (TrackerIndexer *indexer,
item_add_or_update (indexer, info, dirname, basename, metadata);
g_object_unref (metadata);
} else {
item_remove (indexer, info, dirname, basename);
/* Delete events are not atomic, so we don't recurse
* here, since we'll have probably got already events
* from children
*/
item_remove (indexer, info, dirname, basename, FALSE);
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment