[gnome-builder/gnome-builder-3-26] xml-pack: don't ref/unref the completion context
- From: Sébastien Lafargue <slafargue src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder/gnome-builder-3-26] xml-pack: don't ref/unref the completion context
- Date: Wed, 13 Sep 2017 16:39:08 +0000 (UTC)
commit deddf52ac7549980c23bd38be6eaf50d25d8aa90
Author: Sebastien Lafargue <slafargue gnome org>
Date: Wed Sep 13 14:55:15 2017 +0200
xml-pack: don't ref/unref the completion context
Then GtkSourceCompletionContext use a floating ref
so we can't ref/unref it in the populate callback.
(plus we don't really need to here)
plugins/xml-pack/ide-xml-completion-provider.c | 3 +--
1 files changed, 1 insertions(+), 2 deletions(-)
---
diff --git a/plugins/xml-pack/ide-xml-completion-provider.c b/plugins/xml-pack/ide-xml-completion-provider.c
index f19e147..a99f3b6 100644
--- a/plugins/xml-pack/ide-xml-completion-provider.c
+++ b/plugins/xml-pack/ide-xml-completion-provider.c
@@ -99,7 +99,6 @@ populate_state_free (PopulateState *state)
g_assert (state != NULL);
g_object_unref (state->self);
- g_object_unref (state->completion_context);
g_object_unref (state->ifile);
g_object_unref (state->buffer);
}
@@ -1039,7 +1038,7 @@ ide_xml_completion_provider_populate (GtkSourceCompletionProvider *self,
buffer = IDE_BUFFER (gtk_text_iter_get_buffer (&iter));
state->self = g_object_ref (self);
- state->completion_context = g_object_ref (completion_context);
+ state->completion_context = completion_context;
state->buffer = g_object_ref (buffer);
state->ifile = g_object_ref (ide_buffer_get_file (buffer));
state->line = gtk_text_iter_get_line (&iter) + 1;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]