Bug 646457 - Leak in gtkfilechooserdefault.c: search_selected_foreach_get_file_cb
Leak in gtkfilechooserdefault.c: search_selected_foreach_get_file_cb
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: Widget: GtkFileChooser
unspecified
Other All
: Normal normal
: ---
Assigned To: gtk-bugs
Federico Mena Quintero
:
Depends on:
Blocks:
  Show dependency tree
 
Reported: 2011-04-01 17:10 UTC by Morten Welinder
Modified: 2011-04-01 22:43 UTC (History)
0 users

See Also:
GNOME target: ---
GNOME version: ---


Attachments
[filechooser] Don't add extra ref to file, as it it comes from gtk_tree_model_get() (1.08 KB, patch)
2011-04-01 18:27 UTC, Federico Mena Quintero
none Details | Diff | Review

Description Morten Welinder 2011-04-01 17:10:44 UTC
One ref from gtk_tree_model_get, one from g_object_ref.
That doesn't look right.

Note the almost identical function recent_selected_foreach_get_file_cb.
The only difference is that the latter refs only once.
Comment 1 Federico Mena Quintero 2011-04-01 18:27:29 UTC
Created attachment 184886 [details] [review]
[filechooser] Don't add extra ref to file, as it it comes from gtk_tree_model_get()

Leak kindly reported by leak finder extraordinaire Morten Welinder <mortenw@gnome.org>
Comment 2 Federico Mena Quintero 2011-04-01 22:43:55 UTC
Pushed to master.  Thanks for finding this!

Note You need to log in before you can comment on or make changes to this bug.