summaryrefslogtreecommitdiff
path: root/src/nautilus-files-view.c
diff options
context:
space:
mode:
authorCarlos Soriano <csoriano@gnome.org>2016-09-16 10:03:15 +0200
committerCarlos Soriano <csoriano@gnome.org>2016-09-20 16:44:35 +0200
commit6053de7d94c961c9e945a2fcd81f915d9f94bcdc (patch)
treec0249ff10393df99e66fe1e4467148a6fa0a905f /src/nautilus-files-view.c
parente0284d001624ad33f566121fd7223ef9cf80de61 (diff)
downloadnautilus-6053de7d94c961c9e945a2fcd81f915d9f94bcdc.tar.gz
batch-rename-dialog: don't transfer ownership from caller to called
This is common good practice, otherwise it's not clear who has ownership, making it error prone for dangling pointers (this case) or use after free.
Diffstat (limited to 'src/nautilus-files-view.c')
-rw-r--r--src/nautilus-files-view.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/nautilus-files-view.c b/src/nautilus-files-view.c
index d8aa3c6c3..11c5175cc 100644
--- a/src/nautilus-files-view.c
+++ b/src/nautilus-files-view.c
@@ -5971,7 +5971,7 @@ real_action_rename (NautilusFilesView *view)
cursor);
g_object_unref (cursor);
- dialog = nautilus_batch_rename_dialog_new (nautilus_files_view_get_selection (NAUTILUS_VIEW (view)),
+ dialog = nautilus_batch_rename_dialog_new (selection,
nautilus_files_view_get_model (view),
nautilus_files_view_get_window (view));