[Commits] [SCM] claws branch, master, updated. 3.16.0-208-g217451a

wwp at claws-mail.org wwp at claws-mail.org
Mon Jun 11 19:12:59 CEST 2018


The branch, master has been updated
       via  217451accf3ec774a3fefd59b9cec38b5803db26 (commit)
      from  c69dcb6b3ccb4fe9af6d5ed729936a8f17c34d22 (commit)

Summary of changes:
 src/plugins/archive/libarchive_archive.c |   15 ++++++++-------
 1 file changed, 8 insertions(+), 7 deletions(-)


- Log -----------------------------------------------------------------
commit 217451accf3ec774a3fefd59b9cec38b5803db26
Author: wwp <wwp at free.fr>
Date:   Mon Jun 11 19:12:20 2018 +0200

    Reduce scope of few variables.

diff --git a/src/plugins/archive/libarchive_archive.c b/src/plugins/archive/libarchive_archive.c
index 7ee669b..4ee3b6b 100644
--- a/src/plugins/archive/libarchive_archive.c
+++ b/src/plugins/archive/libarchive_archive.c
@@ -441,13 +441,6 @@ const gchar* archive_extract(const char* archive_name, int flags) {
 const gchar* archive_create(const char* archive_name, GSList* files,
 			COMPRESS_METHOD method, ARCHIVE_FORMAT format) {
 	struct archive* arch;
-	struct archive_entry* entry;
-	char* buf = NULL;
-	ssize_t len;
-	int fd;
-	struct file_info* file;
-	gchar* filename = NULL;
-	gchar* msg = NULL;
 
 #ifndef _TEST
 	gint num = 0;
@@ -564,6 +557,9 @@ const gchar* archive_create(const char* archive_name, GSList* files,
 		return archive_error_string(arch);
 
 	while (files && ! stop_action) {
+		struct file_info* file;
+		gchar* filename = NULL;
+
 #ifndef _TEST
 		set_progress_print_all(num++, total, 30);
 #endif
@@ -579,8 +575,13 @@ const gchar* archive_create(const char* archive_name, GSList* files,
 #endif
 		}
 		else {
+			struct archive_entry* entry;
+			char* buf = NULL;
+			ssize_t len;
 			GError* err = NULL;
 			GStatBuf st;
+			int fd;
+			gchar* msg = NULL;
 
 #ifndef _TEST
 			debug_print("Adding: %s\n", filename);

-----------------------------------------------------------------------


hooks/post-receive
-- 
Claws Mail


More information about the Commits mailing list