!6 fix(engrampa):Fix decompress files with garbled characters under GB18030 encoding
From: @longcheng01 Reviewed-by: @peijiankang Signed-off-by: @peijiankang
This commit is contained in:
commit
9863bec01c
@ -0,0 +1,46 @@
|
|||||||
|
From d4d99cd0b2791452e58242373c584c8eeebac2c4 Mon Sep 17 00:00:00 2001
|
||||||
|
From: niko_yhc <yinhongchang@kylinsec.com.cn>
|
||||||
|
Date: Thu, 29 Jun 2023 09:23:48 +0800
|
||||||
|
Subject: [PATCH] fix(engrampa):Fix decompress files with garbled characters
|
||||||
|
under GB18030 encoding
|
||||||
|
MIME-Version: 1.0
|
||||||
|
Content-Type: text/plain; charset=UTF-8
|
||||||
|
Content-Transfer-Encoding: 8bit
|
||||||
|
|
||||||
|
- 修复在GB18030编码下解压文件乱码
|
||||||
|
|
||||||
|
Fixes #7672
|
||||||
|
---
|
||||||
|
src/fr-window.c | 1 +
|
||||||
|
src/main.c | 3 ++-
|
||||||
|
2 files changed, 3 insertions(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/src/fr-window.c b/src/fr-window.c
|
||||||
|
index 080e06a..f7c50f7 100644
|
||||||
|
--- a/src/fr-window.c
|
||||||
|
+++ b/src/fr-window.c
|
||||||
|
@@ -2012,6 +2012,7 @@ fr_window_update_title (FrWindow *window)
|
||||||
|
char *name;
|
||||||
|
|
||||||
|
name = g_uri_display_basename (fr_window_get_archive_uri (window));
|
||||||
|
+ name = g_locale_to_utf8(name, -1, NULL, NULL, NULL);
|
||||||
|
title = g_strdup_printf ("%s %s",
|
||||||
|
name,
|
||||||
|
window->archive->read_only ? _("[read only]") : "");
|
||||||
|
diff --git a/src/main.c b/src/main.c
|
||||||
|
index a9e297d..ba45cbf 100644
|
||||||
|
--- a/src/main.c
|
||||||
|
+++ b/src/main.c
|
||||||
|
@@ -223,7 +223,8 @@ prepare_app (void)
|
||||||
|
char *uri;
|
||||||
|
|
||||||
|
window = fr_window_new ();
|
||||||
|
-
|
||||||
|
+
|
||||||
|
+ filename = g_locale_from_utf8(filename, -1, NULL, NULL, NULL);
|
||||||
|
file = g_file_new_for_commandline_arg (filename);
|
||||||
|
uri = g_file_get_uri (file);
|
||||||
|
fr_window_archive_open (FR_WINDOW (window), uri, GTK_WINDOW (window));
|
||||||
|
--
|
||||||
|
2.27.0
|
||||||
|
|
||||||
@ -14,7 +14,7 @@
|
|||||||
|
|
||||||
Name: engrampa
|
Name: engrampa
|
||||||
Version: 1.24.1
|
Version: 1.24.1
|
||||||
Release: 1
|
Release: 2
|
||||||
Summary: MATE Desktop file archiver
|
Summary: MATE Desktop file archiver
|
||||||
License: GPLv2+ and LGPLv2+
|
License: GPLv2+ and LGPLv2+
|
||||||
URL: http://mate-desktop.org
|
URL: http://mate-desktop.org
|
||||||
@ -33,6 +33,8 @@ BuildRequires: json-glib-devel
|
|||||||
#BuildRequires: caja-devel
|
#BuildRequires: caja-devel
|
||||||
BuildRequires: libSM-devel
|
BuildRequires: libSM-devel
|
||||||
|
|
||||||
|
Patch1: 0004-fix-engrampa-Fix-decompress-files-with-garbled-chara.patch
|
||||||
|
|
||||||
%description
|
%description
|
||||||
Mate File Archiver is an application for creating and viewing archives files,
|
Mate File Archiver is an application for creating and viewing archives files,
|
||||||
such as zip, xv, bzip2, cab, rar and other compress formats.
|
such as zip, xv, bzip2, cab, rar and other compress formats.
|
||||||
@ -95,5 +97,8 @@ find %{buildroot} -name "*.la" -exec rm -f {} ';'
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Thu Jul 20 2023 longcheng <longcheng@kylinos.com.cn> - 1.24.1-2
|
||||||
|
- fix(engrampa):Fix decompress files with garbled characters under GB18030 encoding
|
||||||
|
|
||||||
* Wed Sep 02 2020 douyan <douyan@kylinos.cn> - 1.24.1-1
|
* Wed Sep 02 2020 douyan <douyan@kylinos.cn> - 1.24.1-1
|
||||||
- package init
|
- package init
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user