summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChun-wei Fan <fanchunwei@src.gnome.org>2016-07-11 17:50:13 +0800
committerChun-wei Fan <fanchunwei@src.gnome.org>2016-07-13 11:26:35 +0800
commitd8815f3e4ee090cf22156a96873909db10d384f4 (patch)
tree59fd62011e25219b3ebd702e7421c3aacf3da033
parent500c9dbe96d56895a95b6594c6ab5f011c747e3f (diff)
downloadgtk+-d8815f3e4ee090cf22156a96873909db10d384f4.tar.gz
gtk/gtkfilechoosernativeportal.c: Don't use g_autoptr()
This code is also built by non-GCC/CLang compilers, so use the normal ref/unref steps for the GVariant. https://bugzilla.gnome.org/show_bug.cgi?id=768659
-rw-r--r--gtk/gtkfilechoosernativeportal.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gtk/gtkfilechoosernativeportal.c b/gtk/gtkfilechoosernativeportal.c
index 883861779b..05dedaa225 100644
--- a/gtk/gtkfilechoosernativeportal.c
+++ b/gtk/gtkfilechoosernativeportal.c
@@ -100,7 +100,7 @@ response_cb (GDBusConnection *connection,
const char **uris;
int i;
GVariant *response_data;
- g_autoptr (GVariant) choices = NULL;
+ GVariant *choices = NULL;
g_variant_get (parameters, "(u@a{sv})", &portal_response, &response_data);
g_variant_lookup (response_data, "uris", "^a&s", &uris);
@@ -115,6 +115,7 @@ response_cb (GDBusConnection *connection,
gtk_file_chooser_set_choice (GTK_FILE_CHOOSER (self), id, selected);
}
+ g_variant_unref (choices);
g_slist_free_full (self->custom_files, g_object_unref);
self->custom_files = NULL;
for (i = 0; uris[i]; i++)