[gnome-logs/wip/larsu/listmodel: 15/18] journal: remove query_cursor()
- From: Lars Uebernickel <larsu src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-logs/wip/larsu/listmodel: 15/18] journal: remove query_cursor()
- Date: Sat, 14 Feb 2015 18:48:41 +0000 (UTC)
commit f7035f758cd331dbb7776f1c9494dc19ef196e0f
Author: Lars Uebernickel <lars uebernic de>
Date: Sat Feb 14 19:42:20 2015 +0100
journal: remove query_cursor()
src/gl-journal.c | 50 --------------------------------------------------
src/gl-journal.h | 1 -
2 files changed, 0 insertions(+), 51 deletions(-)
---
diff --git a/src/gl-journal.c b/src/gl-journal.c
index 7fe7a23..b9efab0 100644
--- a/src/gl-journal.c
+++ b/src/gl-journal.c
@@ -505,56 +505,6 @@ gl_journal_set_matches (GlJournal *journal,
priv->mandatory_fields = (gchar **) g_ptr_array_free (mandatory_fields, FALSE);
}
-GlJournalResult *
-gl_journal_query_cursor (GlJournal *self,
- const gchar *cursor)
-{
- GlJournalPrivate *priv;
- sd_journal *journal;
- gint ret;
- GlJournalResult *result = NULL;
-
- g_return_val_if_fail (GL_JOURNAL (self), NULL);
- g_return_val_if_fail (cursor != NULL, NULL);
-
- priv = gl_journal_get_instance_private (self);
- journal = priv->journal;
-
- ret = sd_journal_seek_cursor (journal, cursor);
-
- if (ret < 0)
- {
- g_warning ("Error seeking to cursor position: %s", g_strerror (-ret));
- goto out;
- }
-
- ret = sd_journal_next (journal);
-
- if (ret < 0)
- {
- g_warning ("Error positioning cursor in systemd journal: %s",
- g_strerror (-ret));
- }
-
- ret = sd_journal_test_cursor (journal, cursor);
-
- if (ret < 0)
- {
- g_warning ("Error testing cursor string: %s", g_strerror (-ret));
- goto out;
- }
- else if (ret == 0)
- {
- g_warning ("Cursor string does not match journal entry");
- goto out;
- }
-
- result = _gl_journal_query_result (self);
-
-out:
- return result;
-}
-
static void
gl_journal_result_free (GlJournalResult *result,
G_GNUC_UNUSED gpointer user_data)
diff --git a/src/gl-journal.h b/src/gl-journal.h
index 1733dc3..3b46532 100644
--- a/src/gl-journal.h
+++ b/src/gl-journal.h
@@ -83,7 +83,6 @@ void gl_journal_set_matches (GlJournal *journal, const gchar * const *matches);
GlJournalResult * gl_journal_result_ref (GlJournalResult *result);
void gl_journal_result_unref (GlJournalResult *result);
void gl_journal_results_free (GList *results);
-GlJournalResult * gl_journal_query_cursor (GlJournal *self, const gchar *cursor);
GlJournal * gl_journal_new (void);
G_END_DECLS
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]