[tracker] libtracker-data: Never rollback ontology journal transactions
- From: Jürg Billeter <juergbi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker] libtracker-data: Never rollback ontology journal transactions
- Date: Mon, 31 Jan 2011 14:24:46 +0000 (UTC)
commit d6d618ade9c855e2ac1c49cb2c0d3f41095c4cbc
Author: Jürg Billeter <j bitron ch>
Date: Mon Jan 31 14:03:05 2011 +0100
libtracker-data: Never rollback ontology journal transactions
This is currently not supported but also not necessary as transient
properties are never set in .ontology files.
src/libtracker-data/tracker-data-update.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
---
diff --git a/src/libtracker-data/tracker-data-update.c b/src/libtracker-data/tracker-data-update.c
index 473b78c..94d654e 100644
--- a/src/libtracker-data/tracker-data-update.c
+++ b/src/libtracker-data/tracker-data-update.c
@@ -2480,15 +2480,13 @@ tracker_data_commit_transaction (GError **error)
return;
}
- in_transaction = FALSE;
get_transaction_modseq ();
if (has_persistent && !in_ontology_transaction) {
transaction_modseq++;
}
- in_ontology_transaction = FALSE;
if (!in_journal_replay) {
- if (has_persistent) {
+ if (has_persistent || in_ontology_transaction) {
tracker_db_journal_commit_db_transaction ();
} else {
/* If we only had transient properties, then we must not write
@@ -2497,7 +2495,10 @@ tracker_data_commit_transaction (GError **error)
tracker_db_journal_rollback_transaction ();
}
}
+
resource_time = 0;
+ in_transaction = FALSE;
+ in_ontology_transaction = FALSE;
if (update_buffer.class_counts) {
/* successful transaction, no need to rollback class counts,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]