aboutsummaryrefslogtreecommitdiffstats
path: root/e-util/e-file-utils.c
diff options
context:
space:
mode:
Diffstat (limited to 'e-util/e-file-utils.c')
-rw-r--r--e-util/e-file-utils.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/e-util/e-file-utils.c b/e-util/e-file-utils.c
index 60db352f6d..571154733b 100644
--- a/e-util/e-file-utils.c
+++ b/e-util/e-file-utils.c
@@ -68,20 +68,20 @@ file_replace_contents_cb (GFile *file,
result = e_io_activity_get_async_result (E_IO_ACTIVITY (activity));
- g_object_set_data_full (
- G_OBJECT (result),
- "__new_etag__", new_etag,
- (GDestroyNotify) g_free);
-
- g_simple_async_result_set_op_res_gboolean (
- G_SIMPLE_ASYNC_RESULT (result), success);
-
- if (error != NULL) {
+ if (error == NULL) {
+ g_object_set_data_full (
+ G_OBJECT (result),
+ "__new_etag__", new_etag,
+ (GDestroyNotify) g_free);
+ } else {
g_simple_async_result_set_from_error (
G_SIMPLE_ASYNC_RESULT (result), error);
g_error_free (error);
}
+ g_simple_async_result_set_op_res_gboolean (
+ G_SIMPLE_ASYNC_RESULT (result), success);
+
e_activity_complete (activity);
g_object_unref (activity);