From debfb7a2fea7143eba467300b20e25a2fd735b20 Mon Sep 17 00:00:00 2001 From: Steven Jackson Date: Thu, 7 Nov 2013 15:58:02 +0000 Subject: [PATCH] Fixed a SIGABRT in orage_copy_file. If you attempt to copy/move an empty file using the 'Exchange Data' dialog it will result in a SIGABRT. --- src/functions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/functions.c b/src/functions.c index 1db8093..4c7e68f 100644 --- a/src/functions.c +++ b/src/functions.c @@ -882,7 +882,7 @@ gboolean orage_copy_file(gchar *source, gchar *target) ok = FALSE; } /* write file */ - if (!g_file_set_contents(target, text, -1, &error)) { + if (ok && !g_file_set_contents(target, text, -1, &error)) { orage_message(150, "orage_copy_file: Could not write file (%s) error:%s" , target, error->message); g_error_free(error); -- 1.8.3.2