[tracker/binary-log-2: 13/38] libtracker-db: Fix end of transaction handling when reading journal
- From: Jürg Billeter <juergbi src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [tracker/binary-log-2: 13/38] libtracker-db: Fix end of transaction handling when reading journal
- Date: Tue, 12 Jan 2010 15:57:42 +0000 (UTC)
commit c2169284b66ff228abb49dc1cf49c07707f2d39c
Author: Jürg Billeter <j bitron ch>
Date: Wed Jan 6 15:06:23 2010 +0100
libtracker-db: Fix end of transaction handling when reading journal
src/libtracker-db/tracker-db-journal.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/src/libtracker-db/tracker-db-journal.c b/src/libtracker-db/tracker-db-journal.c
index 7b1b912..98162ba 100644
--- a/src/libtracker-db/tracker-db-journal.c
+++ b/src/libtracker-db/tracker-db-journal.c
@@ -728,11 +728,12 @@ tracker_db_journal_reader_next (GError **error)
} else if (reader.amount_of_triples == 0) {
/* end of transaction */
- if (reader.current + 4 != reader.entry_end) {
+ reader.current += 4;
+ if (reader.current != reader.entry_end) {
/* damaged journal entry */
g_set_error (error, TRACKER_DB_JOURNAL_ERROR, 0,
"Damaged journal entry, %p != %p (end of transaction with 0 triples)",
- reader.current + 4,
+ reader.current,
reader.entry_end);
return FALSE;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]