[nautilus] view: fix mem leak
- From: Cosimo Cecchi <cosimoc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [nautilus] view: fix mem leak
- Date: Thu, 17 Jan 2013 18:35:26 +0000 (UTC)
commit 6cc059717e35ab1c1af98985eb5d46e434d3e949
Author: Pavel Vasin <rat4vier gmail com>
Date: Tue Jan 1 20:26:00 2013 +0400
view: fix mem leak
https://bugzilla.gnome.org/show_bug.cgi?id=691004
src/nautilus-view.c | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/src/nautilus-view.c b/src/nautilus-view.c
index 5ac32d9..144c642 100644
--- a/src/nautilus-view.c
+++ b/src/nautilus-view.c
@@ -1855,6 +1855,7 @@ new_folder_done (GFile *new_folder,
if (data->selection != NULL) {
NewFolderSelectionData *sdata;
GList *uris, *l;
+ char *target_uri;
sdata = g_new (NewFolderSelectionData, 1);
sdata->directory_view = directory_view;
@@ -1879,6 +1880,8 @@ new_folder_done (GFile *new_folder,
}
uris = g_list_reverse (uris);
+ target_uri = nautilus_file_get_uri (file);
+
g_signal_connect_data (directory_view,
"remove_file",
G_CALLBACK (rename_newly_added_folder),
@@ -1889,10 +1892,11 @@ new_folder_done (GFile *new_folder,
nautilus_view_move_copy_items (directory_view,
uris,
NULL,
- nautilus_file_get_uri (file),
+ target_uri,
GDK_ACTION_MOVE,
0, 0);
g_list_free_full (uris, g_free);
+ g_free (target_uri);
} else {
if (g_hash_table_lookup_extended (data->added_locations, new_folder, NULL, NULL)) {
/* The file was already added */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]