[tracker] libtracker-data: Avoid that ontology changes increment the tracker:modified



commit 34fcc1a9bb4bb4b66806b5c040d7754275a5ccfd
Author: Philip Van Hoof <philip codeminded be>
Date:   Fri Jan 28 14:41:21 2011 +0100

    libtracker-data: Avoid that ontology changes increment the tracker:modified

 src/libtracker-data/tracker-data-update.c |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)
---
diff --git a/src/libtracker-data/tracker-data-update.c b/src/libtracker-data/tracker-data-update.c
index ffabaa8..473b78c 100644
--- a/src/libtracker-data/tracker-data-update.c
+++ b/src/libtracker-data/tracker-data-update.c
@@ -464,6 +464,11 @@ get_transaction_modseq (void)
 		transaction_modseq = tracker_data_update_get_next_modseq ();
 	}
 
+	/* Always use 1 for ontology transactions */
+	if (in_ontology_transaction) {
+		return 1;
+	}
+
 	return transaction_modseq;
 }
 
@@ -2477,7 +2482,7 @@ tracker_data_commit_transaction (GError **error)
 
 	in_transaction = FALSE;
 	get_transaction_modseq ();
-	if (has_persistent) {
+	if (has_persistent && !in_ontology_transaction) {
 		transaction_modseq++;
 	}
 	in_ontology_transaction = FALSE;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]