summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorErnestas Kulik <ernestask@gnome.org>2017-05-15 11:21:52 +0300
committerErnestas Kulik <ernestask@gnome.org>2017-05-15 15:06:24 +0300
commit0d207faa308b07425c72391dd0722e2bebd1df5d (patch)
tree6dcb78d60efe996422f0ba5c461811b4b311f0f3
parentb1d57bc5a979aaff20c8f08217de0fd0390a4b38 (diff)
downloadnautilus-0d207faa308b07425c72391dd0722e2bebd1df5d.tar.gz
file-operations: mark_desktop_file_executable: use automatic cleanup
https://bugzilla.gnome.org/show_bug.cgi?id=782650
-rw-r--r--src/nautilus-file-operations.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/nautilus-file-operations.c b/src/nautilus-file-operations.c
index d665e61ba..8d9e0c4f5 100644
--- a/src/nautilus-file-operations.c
+++ b/src/nautilus-file-operations.c
@@ -8110,7 +8110,7 @@ nautilus_file_mark_desktop_file_executable (GFile *file,
NautilusOpCallback done_callback,
gpointer done_callback_data)
{
- GTask *task;
+ g_autoptr (GTask) task = NULL;
MarkTrustedJob *job;
job = op_job_new (MarkTrustedJob, parent_window);
@@ -8122,7 +8122,6 @@ nautilus_file_mark_desktop_file_executable (GFile *file,
task = g_task_new (NULL, NULL, mark_desktop_file_executable_task_done, job);
g_task_set_task_data (task, job, NULL);
g_task_run_in_thread (task, mark_desktop_file_executable_task_thread_func);
- g_object_unref (task);
}
static void