Bugzilla – Attachment 105099 Details for
Bug 25501
Encoding issues in the translation process
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 25501: Supress warnings on installing translation
Bug-25501-Supress-warnings-on-installing-translati.patch (text/plain), 1.65 KB, created by
Jonathan Druart
on 2020-05-19 14:10:39 UTC
(
hide
)
Description:
Bug 25501: Supress warnings on installing translation
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2020-05-19 14:10:39 UTC
Size:
1.65 KB
patch
obsolete
>From 932cb8df1ecc73f2d44df5608ce8ea01addcef77 Mon Sep 17 00:00:00 2001 >From: Julian Maurice <julian.maurice@biblibre.com> >Date: Tue, 19 May 2020 10:05:41 -0300 >Subject: [PATCH] Bug 25501: Supress warnings on installing translation > >To test: >1) Verify the error installing translations for any language >2) Apply the patch >3) Repeat 1), check warning is gone > >Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com> >Attributed to Julian >No warnings, no double encoding, no errors. > >Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Tested full install with yml and js strings, everything works great! >--- > misc/translator/tmpl_process3.pl | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > >diff --git a/misc/translator/tmpl_process3.pl b/misc/translator/tmpl_process3.pl >index 68c58f0cc6..21a19f0011 100755 >--- a/misc/translator/tmpl_process3.pl >+++ b/misc/translator/tmpl_process3.pl >@@ -302,7 +302,7 @@ for my $in_dir ( @in_dirs ) { > } > > # restores the string list from file >-$href = Locale::PO->load_file_ashash($str_file); >+$href = Locale::PO->load_file_ashash($str_file, 'utf-8'); > > # guess the charsets. HTML::Templates defaults to iso-8859-1 > if (defined $href) { >@@ -465,7 +465,7 @@ if ($action eq 'create') { > VerboseWarnings::set_input_file_name $input; > mkdir_recursive($targetdir) unless -d $targetdir; > print STDERR "Creating $target...\n" unless $quiet; >- open( OUTPUT, ">$target" ) || die "$target: $!\n"; >+ open( OUTPUT, ">:encoding(UTF-8)", "$target" ) || die "$target: $!\n"; > text_replace( $h, *OUTPUT ); > close OUTPUT; > } else { >-- >2.20.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 25501
:
104876
|
105043
|
105060
|
105067
|
105073
|
105074
|
105080
|
105081
|
105084
|
105085
|
105095
| 105099