Commit 09670c24 authored by Pavel Vasin's avatar Pavel Vasin Committed by Cosimo Cecchi

file-operations: move: fix potential GError leaks

https://bugzilla.gnome.org/show_bug.cgi?id=682603
parent 21ae8360
......@@ -4835,6 +4835,8 @@ move_file_prepare (CopyMoveJob *move_job,
if (IS_IO_ERROR (error, INVALID_FILENAME) &&
!handled_invalid_filename) {
g_error_free (error);
handled_invalid_filename = TRUE;
g_assert (*dest_fs_type == NULL);
......@@ -4925,6 +4927,7 @@ move_file_prepare (CopyMoveJob *move_job,
/* Other error */
else {
if (job->skip_all_error) {
g_error_free (error);
goto out;
}
primary = f (_("Error while moving “%B”."), src);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment