|
1
|
+From 8cd485a58d865d89d71931b66d7e2cb2202fc1be Mon Sep 17 00:00:00 2001
|
|
2
|
+From: Colomban Wendling <cwendling@hypra.fr>
|
|
3
|
+Date: Wed, 17 Jan 2024 11:57:48 +0100
|
|
4
|
+Subject: [PATCH] Use unar instead of cpio for CPIO archives
|
|
5
|
+
|
|
6
|
+---
|
|
7
|
+ src/fr-command-cpio.c | 6 +++---
|
|
8
|
+ src/fr-command-unarchiver.c | 1 +
|
|
9
|
+ 2 files changed, 4 insertions(+), 3 deletions(-)
|
|
10
|
+
|
|
11
|
+diff --git a/src/fr-command-cpio.c b/src/fr-command-cpio.c
|
|
12
|
+index 1b380ad83..31bd069c2 100644
|
|
13
|
+--- a/src/fr-command-cpio.c
|
|
14
|
++++ b/src/fr-command-cpio.c
|
|
15
|
+@@ -224,7 +224,7 @@ fr_command_cpio_extract (FrCommand *comm,
|
|
16
|
+ }
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+-const char *cpio_mime_type[] = { "application/x-cpio", NULL };
|
|
20
|
++const char *cpio_mime_type[] = { /*"application/x-cpio",*/ NULL };
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+ static const char **
|
|
24
|
+@@ -242,8 +242,8 @@ fr_command_cpio_get_capabilities (FrCommand *comm,
|
|
25
|
+ FrCommandCap capabilities;
|
|
26
|
+
|
|
27
|
+ capabilities = FR_COMMAND_CAN_ARCHIVE_MANY_FILES;
|
|
28
|
+- if (is_program_available (CPIO_PATH, check_command))
|
|
29
|
+- capabilities |= FR_COMMAND_CAN_READ;
|
|
30
|
++/* if (is_program_available (CPIO_PATH, check_command))
|
|
31
|
++ capabilities |= FR_COMMAND_CAN_READ;*/
|
|
32
|
+
|
|
33
|
+ return capabilities;
|
|
34
|
+ }
|
|
35
|
+diff --git a/src/fr-command-unarchiver.c b/src/fr-command-unarchiver.c
|
|
36
|
+index 0a40e6b04..8bc9c75ef 100644
|
|
37
|
+--- a/src/fr-command-unarchiver.c
|
|
38
|
++++ b/src/fr-command-unarchiver.c
|
|
39
|
+@@ -255,6 +255,7 @@ fr_command_unarchiver_handle_error (FrCommand *comm,
|
|
40
|
+ const char *unarchiver_mime_type[] = { "application/zip",
|
|
41
|
+ "application/x-cbr",
|
|
42
|
+ "application/x-rar",
|
|
43
|
++ "application/x-cpio",
|
|
44
|
+ NULL };
|
|
45
|
+
|
|
46
|
+ |