[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
branch master updated: tp/texi2any.pl: update comment on DOC_ENCODING_FO
From: |
Patrice Dumas |
Subject: |
branch master updated: tp/texi2any.pl: update comment on DOC_ENCODING_FOR_INPUT_FILE_NAME on Windows (based on Eli input and tests results). |
Date: |
Tue, 25 Oct 2022 18:47:25 -0400 |
This is an automated email from the git hooks/post-receive script.
pertusus pushed a commit to branch master
in repository texinfo.
The following commit(s) were added to refs/heads/master by this push:
new f76c70737b tp/texi2any.pl: update comment on
DOC_ENCODING_FOR_INPUT_FILE_NAME on Windows (based on Eli input and tests
results).
f76c70737b is described below
commit f76c70737b52a0c3e8b1b97731abb51e15371558
Author: Patrice Dumas <pertusus@free.fr>
AuthorDate: Wed Oct 26 00:46:23 2022 +0200
tp/texi2any.pl: update comment on DOC_ENCODING_FOR_INPUT_FILE_NAME on
Windows (based on Eli input and tests results).
---
tp/texi2any.pl | 12 ++++++++----
1 file changed, 8 insertions(+), 4 deletions(-)
diff --git a/tp/texi2any.pl b/tp/texi2any.pl
index fa2cc88c72..f1573241fa 100755
--- a/tp/texi2any.pl
+++ b/tp/texi2any.pl
@@ -332,10 +332,14 @@ my $main_program_set_options = {
'LOCALE_ENCODING' => $locale_encoding
};
-# use locale on Windows to set encoding of input file name as
-# system calls obey locale pages even if the filesystem uses
-# utf16 internally
-# FIXME better explanation?
+# In Windows, a character in file name is encoded according to the current
+# codepage, and converted to/from UTF-16 in the filesystem. If a file name is
+# not encoded in the current codepage, the file name will appear with erroneous
+# characters when listing file names. Also the encoding and decoding to
+# UTF-16 may fail, especially when the codepage is 8bit while the file name
+# is encoded in a multibyte encoding.
+# We assume that in Windows the file names are reencoded in the current
+# codepage encoding to avoid those issues.
if ($^O eq 'MSWin32') {
$main_program_set_options->{'DOC_ENCODING_FOR_INPUT_FILE_NAME'} = 0;
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- branch master updated: tp/texi2any.pl: update comment on DOC_ENCODING_FOR_INPUT_FILE_NAME on Windows (based on Eli input and tests results).,
Patrice Dumas <=