From c5cfaf9d672bf8f85a29921c11a09787d1c8b613 Mon Sep 17 00:00:00 2001 From: sc0w Date: Fri, 25 Sep 2015 22:29:01 +0200 Subject: unar: fix extracting archives with '[' in filename fixes https://github.com/mate-desktop/engrampa/issues/72 --- src/fr-command-unarchiver.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/fr-command-unarchiver.c b/src/fr-command-unarchiver.c index d13f468..cfeb8c2 100644 --- a/src/fr-command-unarchiver.c +++ b/src/fr-command-unarchiver.c @@ -209,8 +209,13 @@ fr_command_unarchiver_extract (FrCommand *comm, fr_process_add_arg (comm->process, comm->filename); - for (scan = file_list; scan; scan = scan->next) - fr_process_add_arg (comm->process, scan->data); + for (scan = file_list; scan; scan = scan->next) { + char *escaped; + + escaped = escape_str (scan->data, "["); + fr_process_add_arg (comm->process, escaped); + g_free (escaped); + } fr_process_end_command (comm->process); } -- cgit v1.2.1