[tracker] libtracker-miner: Fixed GRAPH in IgnoreNextUpdate case
- From: Philip Van Hoof <pvanhoof src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker] libtracker-miner: Fixed GRAPH in IgnoreNextUpdate case
- Date: Wed, 1 Sep 2010 15:19:54 +0000 (UTC)
commit eaca20deb9a7ca8a7c08b61bf391cecefb8f2e03
Author: Philip Van Hoof <philip codeminded be>
Date: Fri Aug 27 11:02:37 2010 +0200
libtracker-miner: Fixed GRAPH in IgnoreNextUpdate case
src/libtracker-miner/tracker-miner-fs.c | 17 +++++++++--------
src/tracker-store/tracker-resources.c | 4 ++--
2 files changed, 11 insertions(+), 10 deletions(-)
---
diff --git a/src/libtracker-miner/tracker-miner-fs.c b/src/libtracker-miner/tracker-miner-fs.c
index e18a7b2..7dc211d 100644
--- a/src/libtracker-miner/tracker-miner-fs.c
+++ b/src/libtracker-miner/tracker-miner-fs.c
@@ -1497,8 +1497,8 @@ item_add_or_update_cb (TrackerMinerFS *fs,
/* update, delete all statements inserted by miner
except for rdf:type statements as they could cause implicit deletion of user data */
- full_sparql = g_strdup_printf ("DELETE { <%s> ?p ?o } WHERE { GRAPH <%s> { <%s> ?p ?o FILTER (?p != rdf:type) } } %s",
- data->urn, TRACKER_MINER_FS_GRAPH_URN,
+ full_sparql = g_strdup_printf ("DELETE { GRAPH <%s> { <%s> ?p ?o } } WHERE { GRAPH <%s> { <%s> ?p ?o FILTER (?p != rdf:type) } } %s",
+ TRACKER_MINER_FS_GRAPH_URN, data->urn, TRACKER_MINER_FS_GRAPH_URN,
data->urn, tracker_sparql_builder_get_result (data->builder));
} else {
g_debug ("Creating new item '%s'", uri);
@@ -1714,19 +1714,20 @@ item_ignore_next_update (TrackerMinerFS *fs,
/* Perhaps we should move the DELETE to tracker-miner-files.c?
* Or we add support for DELETE to TrackerSparqlBuilder ofcrs */
- query = g_strdup_printf ("DELETE { "
+ query = g_strdup_printf ("DELETE { GRAPH <%s> { "
" ?u nfo:fileSize ?unknown1 ; "
" nfo:fileLastModified ?unknown2 ; "
" nfo:fileLastAccessed ?unknown3 ; "
- " nie:mimeType ?unknown4 "
- "} WHERE { "
+ " nie:mimeType ?unknown4 } "
+ "} WHERE { GRAPH <%s> { "
" ?u nfo:fileSize ?unknown1 ; "
" nfo:fileLastModified ?unknown2 ; "
" nfo:fileLastAccessed ?unknown3 ; "
" nie:mimeType ?unknown4 ; "
- " nie:url \"%s\" "
- "} %s",
- uri, tracker_sparql_builder_get_result (sparql));
+ " nie:url \"%s\" } "
+ "} %s", TRACKER_MINER_FS_GRAPH_URN,
+ TRACKER_MINER_FS_GRAPH_URN, uri,
+ tracker_sparql_builder_get_result (sparql));
tracker_sparql_connection_update_async (tracker_miner_get_connection (TRACKER_MINER (fs)),
query,
diff --git a/src/tracker-store/tracker-resources.c b/src/tracker-store/tracker-resources.c
index 87a712f..e7eb4a3 100644
--- a/src/tracker-store/tracker-resources.c
+++ b/src/tracker-store/tracker-resources.c
@@ -731,8 +731,8 @@ on_statement_deleted (gint graph_id,
{
tracker_events_add_delete (graph_id, subject_id, subject, pred_id,
object_id, object, rdf_types);
-// tracker_writeback_check (graph_id, graph, subject_id, subject, pred_id,
-// object_id, object, rdf_types);
+ tracker_writeback_check (graph_id, graph, subject_id, subject, pred_id,
+ object_id, object, rdf_types);
check_class_signal_signal (user_data);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]