[gtk+] [filechooser] Don't leak a GFile
- From: Federico Mena Quintero <federico src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] [filechooser] Don't leak a GFile
- Date: Fri, 1 Apr 2011 22:43:38 +0000 (UTC)
commit a24f61fb3763c71eccbe4e34efd79e5e19ca1414
Author: Federico Mena Quintero <federico gnome org>
Date: Fri Apr 1 13:25:24 2011 -0600
[filechooser] Don't leak a GFile
Reported by Morten Welinder <mortenw gnome org>
https://bugzilla.gnome.org/show_bug.cgi?id=646458
gtk/gtkfilechooserdefault.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/gtk/gtkfilechooserdefault.c b/gtk/gtkfilechooserdefault.c
index 849bd73..23ca7b2 100644
--- a/gtk/gtkfilechooserdefault.c
+++ b/gtk/gtkfilechooserdefault.c
@@ -10031,13 +10031,15 @@ list_row_activated (GtkTreeView *tree_view,
if (is_folder && file)
{
change_folder_and_display_error (impl, file, FALSE);
- return;
+ goto out;
}
if (impl->action == GTK_FILE_CHOOSER_ACTION_OPEN ||
impl->action == GTK_FILE_CHOOSER_ACTION_SAVE)
g_signal_emit_by_name (impl, "file-activated");
+ out:
+
if (file)
g_object_unref (file);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]