diff options
author | Cosimo Alfarano <cosimo.alfarano@collabora.co.uk> | 2010-03-11 16:07:15 +0100 |
---|---|---|
committer | Cosimo Alfarano <cosimo.alfarano@collabora.co.uk> | 2010-03-12 14:07:50 +0100 |
commit | 6efe62230b4839fe9594bfbdc198c6ee773eb330 (patch) | |
tree | 763112b4bb98257a937cee270a73079a650c0d7e /telepathy-logger/log-store-sqlite.c | |
parent | 41d017bff40ac3ec0794706d2604a7e0f245d0d8 (diff) | |
download | telepathy-logger-6efe62230b4839fe9594bfbdc198c6ee773eb330.tar.gz |
Added TPL_LOG_ENTRY_MSG_ID_IS_VALID(x) macro
Diffstat (limited to 'telepathy-logger/log-store-sqlite.c')
-rw-r--r-- | telepathy-logger/log-store-sqlite.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/telepathy-logger/log-store-sqlite.c b/telepathy-logger/log-store-sqlite.c index aa037b0..5467744 100644 --- a/telepathy-logger/log-store-sqlite.c +++ b/telepathy-logger/log-store-sqlite.c @@ -737,7 +737,7 @@ _insert_to_cache_table (TplLogStore *self, DEBUG ("chat_identifier = %s", identifier); DEBUG ("log_identifier = %s", log_id); DEBUG ("pending_msg_id = %d (%s)", msg_id, - (msg_id != TPL_LOG_ENTRY_MSG_ID_ACKNOWLEDGED ? + (TPL_LOG_ENTRY_MSG_ID_IS_VALID (msg_id) ? "pending" : "acknowledged or sent")); DEBUG ("chatroom = %i", chatroom); DEBUG ("date = %s", date); @@ -770,7 +770,7 @@ _insert_to_cache_table (TplLogStore *self, sqlite3_bind_text (sql, TPL_LOG_STORE_SQLITE_KEY_ACCOUNT, account, -1, SQLITE_TRANSIENT); /* insert NULL if ACKNOWLEDGED (ie sent message's entries, which are created * ACK'd */ - if (msg_id == TPL_LOG_ENTRY_MSG_ID_ACKNOWLEDGED) + if (TPL_LOG_ENTRY_MSG_ID_IS_VALID (msg_id)) sqlite3_bind_null (sql, TPL_LOG_STORE_SQLITE_KEY_PENDING_MSG_ID); else sqlite3_bind_int (sql, TPL_LOG_STORE_SQLITE_KEY_PENDING_MSG_ID, msg_id); |