diff options
| author | Cosimo Alfarano <cosimo.alfarano@collabora.co.uk> | 2010-03-08 13:32:23 +0100 |
|---|---|---|
| committer | Cosimo Alfarano <cosimo.alfarano@collabora.co.uk> | 2010-03-12 14:07:50 +0100 |
| commit | 41d017bff40ac3ec0794706d2604a7e0f245d0d8 (patch) | |
| tree | 8378bb69694a126c402ccb6afe1768544d1fbb38 | |
| parent | 9e0963a47f45fadb5406cb77dab58bbaccaa88b8 (diff) | |
Reintroducing static strings instead for SQL
| -rw-r--r-- | telepathy-logger/log-manager.c | 2 | ||||
| -rw-r--r-- | telepathy-logger/log-store-sqlite.c | 4 | ||||
| -rw-r--r-- | telepathy-logger/util.c | 4 |
3 files changed, 4 insertions, 6 deletions
diff --git a/telepathy-logger/log-manager.c b/telepathy-logger/log-manager.c index 87945240f..90ba3ac3d 100644 --- a/telepathy-logger/log-manager.c +++ b/telepathy-logger/log-manager.c @@ -237,8 +237,6 @@ tpl_log_manager_add_message (TplLogManager *manager, TplLogStore *store = l->data; gboolean result; - DEBUG ("STORE %s", tpl_log_store_get_name (store)); - result = tpl_log_store_add_message (store, message, &loc_error); if (!result) { diff --git a/telepathy-logger/log-store-sqlite.c b/telepathy-logger/log-store-sqlite.c index b9f20a1fd..aa037b055 100644 --- a/telepathy-logger/log-store-sqlite.c +++ b/telepathy-logger/log-store-sqlite.c @@ -951,7 +951,7 @@ tpl_log_store_sqlite_get_pending_messages (TplLogStore *self, else /* get the pending log-ids related to channel */ e = sqlite3_prepare_v2 (priv->db, "SELECT * " - "FROM message_cache" + "FROM message_cache " "WHERE pending_msg_id is NOT NULL AND channel=?", -1, &sql, NULL); if (e != SQLITE_OK) @@ -1041,7 +1041,7 @@ tpl_log_store_sqlite_set_acknowledgment (TplLogStore *self, goto out; } - e = sqlite3_prepare_v2 (priv->db, "UPDATE message_cache" + e = sqlite3_prepare_v2 (priv->db, "UPDATE message_cache " "SET pending_msg_id=NULL " "WHERE log_identifier=?", -1, &sql, NULL); if (e != SQLITE_OK) diff --git a/telepathy-logger/util.c b/telepathy-logger/util.c index 1bfdd91d8..2fe27c029 100644 --- a/telepathy-logger/util.c +++ b/telepathy-logger/util.c @@ -22,7 +22,7 @@ #include "util.h" #include "datetime.h" -#include "log-store-index.h" +#include "log-store-sqlite.h" /* Bug#26838 prevents us to trust Messages' iface message-token * header, so I need to create a token which TPL can trust to be unique @@ -35,7 +35,7 @@ create_message_token (const gchar *channel, GChecksum *log_id = g_checksum_new (G_CHECKSUM_SHA1); gchar *retval; gchar *date = tpl_time_to_string_local (timestamp, - TPL_LOG_STORE_INDEX_TIMESTAMP_FORMAT); + TPL_LOG_STORE_SQLITE_TIMESTAMP_FORMAT); g_checksum_update (log_id, (guchar *) channel, -1); g_checksum_update (log_id, (guchar *) date, -1); |
