background: Handle copy cancellation correctly
Make sure to avoid poking at the panel when the file copy is cancelled.
This commit is contained in:
parent
aecd7c860d
commit
e06657e7da
1 changed files with 5 additions and 3 deletions
|
@ -494,9 +494,11 @@ copy_finished_cb (GObject *source_object,
|
|||
|
||||
if (!g_file_copy_finish (G_FILE (source_object), result, &err))
|
||||
{
|
||||
if (err->code != G_IO_ERROR_CANCELLED)
|
||||
g_warning ("Failed to copy image to cache location: %s", err->message);
|
||||
|
||||
if (g_error_matches (err, G_IO_ERROR, G_IO_ERROR_CANCELLED)) {
|
||||
g_error_free (err);
|
||||
return;
|
||||
}
|
||||
g_warning ("Failed to copy image to cache location: %s", err->message);
|
||||
g_error_free (err);
|
||||
}
|
||||
item = g_object_get_data (source_object, "item");
|
||||
|
|
Loading…
Add table
Reference in a new issue