From unknown Mon Aug 11 18:54:49 2025 X-Loop: help-debbugs@gnu.org Subject: bug#75207: 29.4; Path conversion from native codepage to UTF-8 fails when Windows is set by default to UTF-8 Resent-From: michal@0lock.xyz Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 30 Dec 2024 18:30:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 75207 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 75207@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.173558339431956 (code B ref -1); Mon, 30 Dec 2024 18:30:02 +0000 Received: (at submit) by debbugs.gnu.org; 30 Dec 2024 18:29:54 +0000 Received: from localhost ([127.0.0.1]:59925 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tSKWV-0008JH-Va for submit@debbugs.gnu.org; Mon, 30 Dec 2024 13:29:54 -0500 Received: from lists.gnu.org ([209.51.188.17]:57782) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tSEd8-000605-19 for submit@debbugs.gnu.org; Mon, 30 Dec 2024 07:12:18 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tSEd7-00067d-R0 for bug-gnu-emacs@gnu.org; Mon, 30 Dec 2024 07:12:17 -0500 Received: from mail-4022.proton.ch ([185.70.40.22]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tSEd5-0003h0-1T for bug-gnu-emacs@gnu.org; Mon, 30 Dec 2024 07:12:17 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=0lock.xyz; s=protonmail; t=1735560725; x=1735819925; bh=ZvPWjQ/zAL73fSPc5zrZ9YyghnJJuMHTnvW6I5L42AU=; h=Date:To:From:Subject:Message-ID:Feedback-ID:From:To:Cc:Date: Subject:Reply-To:Feedback-ID:Message-ID:BIMI-Selector: List-Unsubscribe:List-Unsubscribe-Post; b=IGsHo5FUeKzXllS7N571DeW8jZZR8S2EUC4MkPtwpuA75A/VA8TNXffemtIjrV8zu 5EepGU16yo6MxWUFwl9IX6nxWJVDHlNroJ/v6sIXPxFT+nu5KjmNUzV46C28L5KEgT a9UUg2CTU2REpj01D+G2holBGaEAJ6O+q09XlL+3/MXsmD6yi4o4okbYNc8GD9nYjz S6Ca5vSxFD17iuToBnJs1nhtdcrmSA1/h+Z1CtC6XbBrhcBKduuQQGDwIk9DAz6zZk qafkESZ1E5llUTyomX5oy8fk+eCFMJj1Xi/H/Kta/K3/lWkv/ds8wPNF7pPg30S9PW Hfmjh4EOUeNAg== Date: Mon, 30 Dec 2024 12:12:02 +0000 From: michal@0lock.xyz Message-ID: <000001db5ab4$06cec970$146c5c50$@0lock.xyz> Feedback-ID: 123495485:user:proton X-Pm-Message-ID: 3185ff365b2172afad6fad09e05542187796efc4 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=185.70.40.22; envelope-from=michal@0lock.xyz; helo=mail-4022.proton.ch X-Spam_score_int: 24 X-Spam_score: 2.4 X-Spam_bar: ++ X-Spam_report: (2.4 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FROM_SUSPICIOUS_NTLD=0.498, FROM_SUSPICIOUS_NTLD_FP=1.997, PDS_OTHER_BAD_TLD=1.997, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H4=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Mailman-Approved-At: Mon, 30 Dec 2024 13:29:50 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) Emacs generates gibberish UTF-8 characters during conversion from native codepage to UTF-8 if experimental default UTF-8 codepage is set on Windows. In GNU Emacs 29.4 (build 2, x86_64-w64-mingw32) of 2024-07-05 built on AVALON Windowing system distributor 'Microsoft Corp.', version 10.0.22631 System Description: Microsoft Windows 10 Education (v10.0.2009.22631.4602) Configured using: 'configure --with-modules --without-dbus --with-native-compilation=3Daot --without-compress-install --with-sqlite3 --with-tree-sitter CFLAGS=3D-O2' Configured features: ACL GIF GMP GNUTLS HARFBUZZ JPEG JSON LCMS2 LIBXML2 MODULES NATIVE_COMP NOTIFY W32NOTIFY PDUMPER PNG RSVG SOUND SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER WEBP XPM ZLIB (NATIVE_COMP present but libgccjit not available) Important settings: value of $LANG: ENG locale-coding-system: cp65001 Major mode: recentf-dialog Minor modes in effect: global-company-mode: t company-mode: t nyan-mode: t fido-vertical-mode: t icomplete-vertical-mode: t icomplete-mode: t fido-mode: t global-display-line-numbers-mode: t display-line-numbers-mode: t recentf-mode: t global-display-fill-column-indicator-mode: t display-fill-column-indicator-mode: t tooltip-mode: t global-eldoc-mode: t show-paren-mode: t electric-indent-mode: t mouse-wheel-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t column-number-mode: t line-number-mode: t transient-mark-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t Load-path shadows: c:/Users/Micha=C5=82/.emacs.d/elpa/transient-20241102.1229/transient hides = c:/Program Files/Emacs/emacs-29.4/share/emacs/29.4/lisp/transient c:/Users/Micha=C5=82/.emacs.d/elpa/standard-themes-2.1.0/theme-loaddefs hid= es c:/Program Files/Emacs/emacs-29.4/share/emacs/29.4/lisp/theme-loaddefs Features: (shadow sort mail-extr emacsbug message yank-media puny dired dired-loaddefs rfc822 mml mml-sec epa epg rfc6068 epg-config gnus-util time-date mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils eldoc-box high-theme company-oddmuse company-keywords company-etags etags fileloop generator xref project company-gtags company-dabbrev-code company-dabbrev company-files company-clang company-capf company-cmake company-semantic company-template company-bbdb company nyan-mode icomplete display-line-numbers recentf tree-widget wid-edit easy-mmode display-fill-column-indicator jai-mode derived compile text-property-search comint ansi-osc ansi-color ring js c-ts-common treesit imenu cc-mode cc-fonts cc-guess cc-menus cc-cmds cc-styles cc-align cc-engine cc-vars cc-defs theme-switcher finder-inf almost-mono-themes-autoloads auctex-autoloads tex-site centered-window-autoloads cmake-mode-autoloads company-autoloads dtrt-indent-autoloads editorconfig-autoloads eldoc-box-autoloads erlang-autoloads exec-path-from-shell-autoloads go-mode-autoloads gruber-darker-theme-autoloads haskell-mode-autoloads highlight-symbol-autoloads latex-preview-pane-autoloads magit-autoloads pcase magit-section-autoloads dash-autoloads markdown-mode-autoloads merlin-autoloads multiple-cursors-autoloads nyan-mode-autoloads powershell-autoloads projectile-autoloads rg-autoloads rust-mode-autoloads slime-autoloads macrostep-autoloads solarized-theme-autoloads standard-themes-autoloads swift-mode-autoloads transient-autoloads tuareg-autoloads rx caml-autoloads wgrep-autoloads white-sand-theme-autoloads with-editor-autoloads info compat-autoloads yasnippet-autoloads zig-mode-autoloads reformatter-autoloads package browse-url url url-proxy url-privacy url-expand url-methods url-history url-cookie generate-lisp-file url-domsuf url-util mailcap url-handlers url-parse auth-source cl-seq eieio eieio-core cl-macs password-cache json subr-x map byte-opt gv bytecomp byte-compile url-vars cl-loaddefs cl-lib rmc iso-transl tooltip cconv eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode mwheel dos-w32 ls-lisp disp-table term/w32-win w32-win w32-vars term/common-win tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors frame minibuffer nadvice seq simple cl-generic indonesian philippine cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite emoji-zwj charscript charprop case-table epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button loaddefs theme-loaddefs faces cus-face macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget keymap hashtable-print-readable backquote threads w32notify w32 lcms2 multi-tty make-network-process native-compile emacs) Memory information: ((conses 16 185675 75051) (symbols 48 14661 7) (strings 32 55444 14585) (string-bytes 1 1821337) (vectors 16 27409) (vector-slots 8 520326 162526) (floats 8 83 1011) (intervals 56 494 150) (buffers 984 11)) From unknown Mon Aug 11 18:54:49 2025 X-Loop: help-debbugs@gnu.org Subject: bug#75207: 29.4; Path conversion from native codepage to UTF-8 fails when Windows is set by default to UTF-8 Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 30 Dec 2024 19:14:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 75207 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: michal@0lock.xyz Cc: 75207@debbugs.gnu.org Received: via spool by 75207-submit@debbugs.gnu.org id=B75207.17355860038127 (code B ref 75207); Mon, 30 Dec 2024 19:14:02 +0000 Received: (at 75207) by debbugs.gnu.org; 30 Dec 2024 19:13:23 +0000 Received: from localhost ([127.0.0.1]:60004 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tSLCc-000270-Vk for submit@debbugs.gnu.org; Mon, 30 Dec 2024 14:13:23 -0500 Received: from eggs.gnu.org ([209.51.188.92]:53306) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tSLCX-00026h-A6; Mon, 30 Dec 2024 14:13:21 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tSLCR-0000nI-Pf; Mon, 30 Dec 2024 14:13:11 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=ftIJ1VALSbfHJgj5B/XMlvGYK1///Bup+P5FS2EJuB4=; b=aIk2fWdy+xWD c6q029Zcyl3+0F3lrp8JQQiA3mQMLW6377HHHrLtRUVMZ+VoMVVwulyPY1cAgJHQmo/iWD00Zacay zrbAbBlyUOqscGLcdWnJpBNZ4/WX8GuaBwdrVgEhYLJltgPNQHresAGWnaBuyzYoQeKoBB8wbNx0e vmeS379eCf9z8H6qyQCUw/b3t3r8NwxNy/+h00gq2TdLgfowHvKpoBR8rLRbcAc9txkFSCpAtUv+J YsYsgQO/o2EWEZrMIqCd0LQc3YnJYQVM0MjgpQUIipucITVXbLyfT/R6A5kp/nPD+kBZutFEbWNnV AdEDMVAnWboyCZZ6rAE13Q==; Date: Mon, 30 Dec 2024 21:13:07 +0200 Message-Id: <86a5cdnfwc.fsf@gnu.org> From: Eli Zaretskii In-Reply-To: <000001db5ab4$06cec970$146c5c50$@0lock.xyz> (bug-gnu-emacs@gnu.org) References: <000001db5ab4$06cec970$146c5c50$@0lock.xyz> X-Spam-Score: -2.3 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) severity 75207 wishlist thanks > Date: Mon, 30 Dec 2024 12:12:02 +0000 > From: michal--- via "Bug reports for GNU Emacs, > the Swiss army knife of text editors" > > Emacs generates gibberish UTF-8 characters during conversion from native > codepage to UTF-8 if experimental default UTF-8 codepage is set on > Windows. Please provide the minimum recipe for reproducing this, starting from "emacs -Q". What exactly did you convert, and how? And what problems did you see, exactly? Also, what do the following commands produce inside "emacs -Q"? M-: (getenv "ENU") RET M-: current-locale-environment RET M-: w32-ansi-code-page RET M-: (default-value 'buffer-file-coding-system) RET In general, the UTF-8 codepage on Windows is not (yet) supported. In particular, some functions we use in Emacs assume the system codepage cannot be a multibyte encoding. Also, invoking subprocesses on Windows doesn't currently support anything but single-byte encoding of the program's name and its command-line arguments, for boring technical reasons. For that reason, I don't recommend using the UTF-8 codepage, and I don't recommend making UTF-8 the default encoding on MS-Windows. That said, presenting a clear recipe could help us gradually improve support for this, as Windows improves its part in parallel. Thanks. From unknown Mon Aug 11 18:54:49 2025 X-Loop: help-debbugs@gnu.org Subject: bug#75207: Fwd: bug#75207: 29.4; Path conversion from native codepage to UTF-8 fails when Windows is set by default to UTF-8 Resent-From: =?UTF-8?Q?Micha=C5=82?= Lach Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 03 Jan 2025 13:21:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 75207 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 75207@debbugs.gnu.org Cc: Eli Zaretskii Received: via spool by 75207-submit@debbugs.gnu.org id=B75207.173591042326547 (code B ref 75207); Fri, 03 Jan 2025 13:21:02 +0000 Received: (at 75207) by debbugs.gnu.org; 3 Jan 2025 13:20:23 +0000 Received: from localhost ([127.0.0.1]:50007 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tThbB-0006u0-JG for submit@debbugs.gnu.org; Fri, 03 Jan 2025 08:20:23 -0500 Received: from mail-10625.protonmail.ch ([79.135.106.25]:41869) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tTgBY-0002fu-MP for 75207@debbugs.gnu.org; Fri, 03 Jan 2025 06:49:49 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=0lock.xyz; s=protonmail; t=1735904978; x=1736164178; bh=Qwr259nq/IghwD+10Br9r4lqY45fceNP5LLifMzdHmY=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector:List-Unsubscribe:List-Unsubscribe-Post; b=2lO3YFBRGRQWSbl8vn87PgbiukWAw6Y7z7Kr576JGhZLQs7xGgeJMqjKBYjXLmPOV yXyrsnNT+f++a7qZtZkIyK+SKe1LxVYkmyWlhsVotMir91eo6PzDTY94P8PCErMxv2 5zxGAywfr/pbasa45PAylZX+z1L5Gk+B5svHdvBXLk/OuLS5uNt9tPL9m24YPiH5Hb UcyuFC5kcnS/6q5tPvWC92+RJE1BCaZYWznfujwmJjrXU9+cfj2peBv2Be+pl424bk wyvBXO/NhOWM74A8AsKcfjOvVSBISAi2BuEzknDCrkQEqT7F21k27/CZ/ySNvQ42mI 1FzrY3ajA+RiA== Date: Fri, 03 Jan 2025 11:49:34 +0000 From: =?UTF-8?Q?Micha=C5=82?= Lach Message-ID: <87F91035-E0D9-4650-B332-10E4E8AD0AEF@0lock.xyz> In-Reply-To: <003001db5d81$a8f144b0$fad3ce10$@0lock.xyz> References: <000001db5ab4$06cec970$146c5c50$@0lock.xyz> <3gvOgDDbA00XBG4Xyu7q8lDJKQVYNo4pJ_Uzu35u0KNS8rhQ9PrenO2Kcz7GDHPNtUng9gnBpgPXtHMty_d_Bw==@protonmail.internalid> <86a5cdnfwc.fsf@gnu.org> <003001db5d81$a8f144b0$fad3ce10$@0lock.xyz> Feedback-ID: 123495485:user:proton X-Pm-Message-ID: 70e9ba3caf94c8b19096fd90bbaa280f0e422766 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Mailman-Approved-At: Fri, 03 Jan 2025 08:20:14 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Forgot to CC the bug report mail. > Begin forwarded message: >=20 > From: > Subject: RE: bug#75207: 29.4; Path conversion from native codepage to UTF= -8 fails when Windows is set by default to UTF-8 > Date: 3 January 2025 at 02:48:53 CET > To: "'Eli Zaretskii'" > Reply-To: >=20 > M-: (getenv "ENU") -> nil > M-: current-locale-environment -> "ENG" > M-: w32-ansi-code-page -> 65001 > M-: (default-value 'buffer-file-coding-system) -> iso-latin-1-dos >=20 >> That said, presenting a clear recipe could help us gradually improve=20 >> support for >> this, as Windows improves its part in parallel. >=20 > Here is the repro. > 1. Put a path to your "PATH" environmental variable with some diacritic= =20 > character (=C5=82 in my case, maybe it won't work for some) > 2. M-: exec-path returns gibberish >=20 > Here, "Micha=C5=82" becomes "Micha=C3=85=E2=80=9A", you can get a similar= result if you do=20 > MultiByteToWideChar using Windows-1252 codepage on a UTF-8 path. >=20 > I've digged around and it looks like codepage_for_filenames (src/w32.c) a= t=20 > somepoint returns the Windows-1252 codepage. > This is then passed to MultiByteToWideChar() and the scenario that I=20 > described above happens. > I've checked this hypothesis with API Monitor and this is what actually= =20 > happens, I can attach a trace if you will find it useful. From unknown Mon Aug 11 18:54:49 2025 X-Loop: help-debbugs@gnu.org Subject: bug#75207: Fwd: bug#75207: 29.4; Path conversion from native codepage to UTF-8 fails when Windows is set by default to UTF-8 Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 03 Jan 2025 13:24:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 75207 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: =?UTF-8?Q?Micha=C5=82?= Lach Cc: 75207@debbugs.gnu.org Received: via spool by 75207-submit@debbugs.gnu.org id=B75207.173591064227063 (code B ref 75207); Fri, 03 Jan 2025 13:24:03 +0000 Received: (at 75207) by debbugs.gnu.org; 3 Jan 2025 13:24:02 +0000 Received: from localhost ([127.0.0.1]:50015 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tThej-00072L-2K for submit@debbugs.gnu.org; Fri, 03 Jan 2025 08:24:01 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:40120) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tTheh-00071t-LY for 75207@debbugs.gnu.org; Fri, 03 Jan 2025 08:24:00 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tTheb-0005RS-Q2; Fri, 03 Jan 2025 08:23:54 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=HoPDNgzmk2BQSRuRkreqmaIQu3OYDU5+jblNWdFZbkQ=; b=sbMirA+GbL5qfswAnHE/ sbqx31vKnFRypP+7ENzjslO2UtUVqPYjX8GK3/4AdJWJeScHe2syGaIpizziB5wxLQgFRbsdmGqoP wd70r8rp/YZleZ7/TA6x4Tczvy44dFD2RfYQNNDc+n35KXtxv93edQcbFd3X5zTL3FPOnIQTT0+0M ZUvkIEEH39rk+1tq44ZEz2UM8PNaApLZdNkVnNEt8Za3ngGrUOK94hTh8bmEYI62c9sV88ZhlTix9 RjZhOrcjEgoxmIJDS7lodvOIfwKjr31gULMX5xO4njFy4UJa+XQzj81C7OWCnV6iALXWP/z1JLwsO gvIWiWO22o9x7g==; Date: Fri, 03 Jan 2025 15:23:48 +0200 Message-Id: <86ed1kghej.fsf@gnu.org> From: Eli Zaretskii In-Reply-To: <87F91035-E0D9-4650-B332-10E4E8AD0AEF@0lock.xyz> (message from =?UTF-8?Q?Micha=C5=82?= Lach on Fri, 03 Jan 2025 11:49:34 +0000) References: <000001db5ab4$06cec970$146c5c50$@0lock.xyz> <3gvOgDDbA00XBG4Xyu7q8lDJKQVYNo4pJ_Uzu35u0KNS8rhQ9PrenO2Kcz7GDHPNtUng9gnBpgPXtHMty_d_Bw==@protonmail.internalid> <86a5cdnfwc.fsf@gnu.org> <003001db5d81$a8f144b0$fad3ce10$@0lock.xyz> <87F91035-E0D9-4650-B332-10E4E8AD0AEF@0lock.xyz> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > Date: Fri, 03 Jan 2025 11:49:34 +0000 > From: Michał Lach > Cc: Eli Zaretskii > > Forgot to CC the bug report mail. > > > Begin forwarded message: > > > > From: > > Subject: RE: bug#75207: 29.4; Path conversion from native codepage to UTF-8 fails when Windows is set by default to UTF-8 > > Date: 3 January 2025 at 02:48:53 CET > > To: "'Eli Zaretskii'" > > Reply-To: > > > > M-: (getenv "ENU") -> nil > > M-: current-locale-environment -> "ENG" > > M-: w32-ansi-code-page -> 65001 > > M-: (default-value 'buffer-file-coding-system) -> iso-latin-1-dos OK. I think I see the problem (and it is not specific to UTF-8 codepage), but just to be sure, please show some more values: M-: w32-multibyte-code-page RET M-: locale-coding-system RET M-: file-name-coding-system RET M-: default-file-name-coding-system RET > > Here is the repro. > > 1. Put a path to your "PATH" environmental variable with some diacritic > > character (ł in my case, maybe it won't work for some) > > 2. M-: exec-path returns gibberish > > > > Here, "Michał" becomes "MichaÅ‚", you can get a similar result if you do > > MultiByteToWideChar using Windows-1252 codepage on a UTF-8 path. We think that PATH is encoded in Windows-1252 codepage, and the question is why and where do we err. The above additional values I ask about might help answer that question. > > I've digged around and it looks like codepage_for_filenames (src/w32.c) at > > somepoint returns the Windows-1252 codepage. > > This is then passed to MultiByteToWideChar() and the scenario that I > > described above happens. > > I've checked this hypothesis with API Monitor and this is what actually > > happens, I can attach a trace if you will find it useful. Not necessary for now, thanks. If I send you a C-level patch, are you able to build Emacs after patching it, preferably the master branch of our Git repository? From unknown Mon Aug 11 18:54:49 2025 X-Loop: help-debbugs@gnu.org Subject: bug#75207: Fwd: bug#75207: 29.4; Path conversion from native codepage to UTF-8 fails when Windows is set by default to UTF-8 Resent-From: michal@0lock.xyz Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 03 Jan 2025 15:23:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 75207 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 'Eli Zaretskii' Cc: 75207@debbugs.gnu.org Received: via spool by 75207-submit@debbugs.gnu.org id=B75207.173591777221166 (code B ref 75207); Fri, 03 Jan 2025 15:23:02 +0000 Received: (at 75207) by debbugs.gnu.org; 3 Jan 2025 15:22:52 +0000 Received: from localhost ([127.0.0.1]:51603 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tTjVj-0005VF-A1 for submit@debbugs.gnu.org; Fri, 03 Jan 2025 10:22:52 -0500 Received: from mail-4018.proton.ch ([185.70.40.18]:51397) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tTim0-0002ec-4I for 75207@debbugs.gnu.org; Fri, 03 Jan 2025 09:35:39 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=0lock.xyz; s=protonmail; t=1735914929; x=1736174129; bh=GJS5AS55bBPqvqrQJ1VAlmi0BXukjdA6oPC/rkY59dI=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector:List-Unsubscribe:List-Unsubscribe-Post; b=PQjktfe4fW0E2HcEroVIW9oCRWwHIE7bOgRnKy/DmYxfrC21/i3wgAq7qDnaoKItG eDiTe/wCNacQYsPekp5sGaIHpgkNsWn3IgJmzlQV1RB8sK2mFZeNtkJNd+eXboiNIV Szi0wO/4cibiscxw1S+SXqCyA1Tbr7nOteYU46QBF908TgaEP6L0ddSggGlXOSrx1B JYyHzUJaOGisd+YNSvujsPZumYI2kMg3jKyhv15Nwes4nwZo4UZVJxetkQ707WNxFg Fs4AcR6VyWHQtES3rz45TKjRpm0Rz8J1sIopHWjxioGmVT9ZNo14u8BazFKacTTR3r 7A5/oLedpaFgQ== Date: Fri, 03 Jan 2025 14:35:26 +0000 From: michal@0lock.xyz Message-ID: <000701db5dec$b8751ef0$295f5cd0$@0lock.xyz> In-Reply-To: <86ed1kghej.fsf@gnu.org> References: <000001db5ab4$06cec970$146c5c50$@0lock.xyz> <3gvOgDDbA00XBG4Xyu7q8lDJKQVYNo4pJ_Uzu35u0KNS8rhQ9PrenO2Kcz7GDHPNtUng9gnBpgPXtHMty_d_Bw==@protonmail.internalid> <86a5cdnfwc.fsf@gnu.org> <003001db5d81$a8f144b0$fad3ce10$@0lock.xyz> <87F91035-E0D9-4650-B332-10E4E8AD0AEF@0lock.xyz> <86ed1kghej.fsf@gnu.org> Feedback-ID: 123495485:user:proton X-Pm-Message-ID: 2d6f27744493f0b7a8779b9f26761b036e2a4812 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Mailman-Approved-At: Fri, 03 Jan 2025 10:22:49 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) I've just built Emacs on somewhat new revision (577714e3fe) and cannot repr= o it there. Tag emacs-29.1 does not build by default on Windows so I didn't check. My theory is that maybe the codepage of the machine Emacs was built on infl= uences this?? Or this has just been fixed on the latest version. I debugged a bit and it looks like w32_ansi_code_page is set to 1252 at som= e point. > OK. I think I see the problem (and it is not specific to UTF-8 codepage)= , but > just to be sure, please show some more values: >=20 > M-: w32-multibyte-code-page RET > M-: locale-coding-system RET > M-: file-name-coding-system RET > M-: default-file-name-coding-system RET >=20 M-: w32-multibyte-code-page -> 0 M-: locale-coding-system -> cp65001 M-: file-name-coding-system -> nil M-: default-file-name-coding-system -> cp65001 > We think that PATH is encoded in Windows-1252 codepage, and the question > is why and where do we err. The above additional values I ask about migh= t > help answer that question. I can say for sure that it is not, API monitor trace confirms this as well = as some basic Win32 programs. getenv("PATH") returns proper string, respecting the active code page. =20 > If I send you a C-level patch, are you able to build Emacs after patching= it, > preferably the master branch of our Git repository? Sure. From unknown Mon Aug 11 18:54:49 2025 X-Loop: help-debbugs@gnu.org Subject: bug#75207: Fwd: bug#75207: 29.4; Path conversion from native codepage to UTF-8 fails when Windows is set by default to UTF-8 Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 03 Jan 2025 15:26:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 75207 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: michal@0lock.xyz Cc: 75207@debbugs.gnu.org Received: via spool by 75207-submit@debbugs.gnu.org id=B75207.173591794521944 (code B ref 75207); Fri, 03 Jan 2025 15:26:01 +0000 Received: (at 75207) by debbugs.gnu.org; 3 Jan 2025 15:25:45 +0000 Received: from localhost ([127.0.0.1]:51611 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tTjYW-0005hr-V1 for submit@debbugs.gnu.org; Fri, 03 Jan 2025 10:25:45 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:46330) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tTjYU-0005he-V0 for 75207@debbugs.gnu.org; Fri, 03 Jan 2025 10:25:43 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tTjYP-0001qO-JX; Fri, 03 Jan 2025 10:25:37 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=VDBytIlSkiX6l8ZTsmZ/AQlkXTJ3E4RMDfuXyTYZCv4=; b=RwM0wd84iz3U hmMZ/WfHhdvh9xg5ogQkbTyvS3Op7gF+/ttEhzSef7uoonFOsLPKAm2M9EPovo7i0dzYshsRr/Yh3 17MOfuqf8mclaH/eg/U+ldvsaxIAxYWyDZ1EhxrFoZrzEwaNgZYI5c++GTYqr24Y2C+DP7J7YkaIm htexjymczBUT1+0Kz/26PtbSaWOeuFkwKQHF/xCYAIoMwZ5pJ3yuVufYy8EZ7rI28bhPuNXsltYEk t/ZGhdlQNRfdgpNsfNVr7EZWP4WXYzvA57NiBunMeZIt97ZfCXn+TawBsZovFUD8vffTN6IOjSjN4 3vrXM+zqVvu8RnEch+6CfA==; Date: Fri, 03 Jan 2025 17:25:31 +0200 Message-Id: <86a5c7hqc4.fsf@gnu.org> From: Eli Zaretskii In-Reply-To: <000701db5dec$b8751ef0$295f5cd0$@0lock.xyz> (michal@0lock.xyz) References: <000001db5ab4$06cec970$146c5c50$@0lock.xyz> <3gvOgDDbA00XBG4Xyu7q8lDJKQVYNo4pJ_Uzu35u0KNS8rhQ9PrenO2Kcz7GDHPNtUng9gnBpgPXtHMty_d_Bw==@protonmail.internalid> <86a5cdnfwc.fsf@gnu.org> <003001db5d81$a8f144b0$fad3ce10$@0lock.xyz> <87F91035-E0D9-4650-B332-10E4E8AD0AEF@0lock.xyz> <86ed1kghej.fsf@gnu.org> <000701db5dec$b8751ef0$295f5cd0$@0lock.xyz> X-Spam-Score: -2.3 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > Date: Fri, 03 Jan 2025 14:35:26 +0000 > From: michal@0lock.xyz > Cc: 75207@debbugs.gnu.org > > I've just built Emacs on somewhat new revision (577714e3fe) and cannot repro it there. > Tag emacs-29.1 does not build by default on Windows so I didn't check. > > My theory is that maybe the codepage of the machine Emacs was built on influences this?? Yes, it does, according to my reading of the code. When we went from unexec to pdumper builds, we introduced a bug whereby the relevant variables are assigned values that come from the dump stage, and not reinitialized after that. If Emacs was dumped when the system codepage was different, you will see problems when the dumped Emacs starts with a different codepage, AFAICT. As I said, this is not limited to UTF-8, so it is good we found this problem. > Or this has just been fixed on the latest version. No, I don't think so. I see the problem on the latest master branch. > I debugged a bit and it looks like w32_ansi_code_page is set to 1252 at some point. AFAICT, that happens when we load the pdumper file. > M-: w32-multibyte-code-page -> 0 > M-: locale-coding-system -> cp65001 > M-: file-name-coding-system -> nil > M-: default-file-name-coding-system -> cp65001 OK, I think this confirms my hypothesis. I'll try to come up with a patch, probably tomorrow. > > We think that PATH is encoded in Windows-1252 codepage, and the question > > is why and where do we err. The above additional values I ask about might > > help answer that question. > > I can say for sure that it is not When I say "we think", I mean Emacs thinks that, mistakenly. > > If I send you a C-level patch, are you able to build Emacs after patching it, > > preferably the master branch of our Git repository? > > Sure. OK, but you'll need to build Emacs with a different system codepage to see the effects of the fix. From unknown Mon Aug 11 18:54:49 2025 X-Loop: help-debbugs@gnu.org Subject: bug#75207: Fwd: bug#75207: 29.4; Path conversion from native codepage to UTF-8 fails when Windows is set by default to UTF-8 Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 04 Jan 2025 09:31:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 75207 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: michal@0lock.xyz Cc: 75207@debbugs.gnu.org Received: via spool by 75207-submit@debbugs.gnu.org id=B75207.173598304721117 (code B ref 75207); Sat, 04 Jan 2025 09:31:02 +0000 Received: (at 75207) by debbugs.gnu.org; 4 Jan 2025 09:30:47 +0000 Received: from localhost ([127.0.0.1]:53379 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tU0UZ-0005UW-0D for submit@debbugs.gnu.org; Sat, 04 Jan 2025 04:30:47 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:52564) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tU0UW-0005UG-Gn for 75207@debbugs.gnu.org; Sat, 04 Jan 2025 04:30:45 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tU0UQ-0008LU-Sv; Sat, 04 Jan 2025 04:30:38 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=a835THeZIgPRoqaXyzY2JdaXnTAXpWXoO1HkGCdwdSQ=; b=mUPrquomTJi6 aAUUMBrFVBnYeSe91pHOy2/0Cn3GV1arb9taLMR4bFhz6VHjkDIvaf8kUbx4TPz6Wuml+33RNuPnl 3plfa4RepJIAe6+urGKb/JMLksbsRExHo4a3zDFjxyyWV5M9MiUoDjm0HapiLZBV+Q60TeFUpakbT 39Mq4Ud4VgukaPOtdah7G99VKatTHJIw0IlBO7bXwi7WdpNMAvPjMG5Ifkiwe8FulasXbzRxg2l0d HvfC4V8CzanBvvUdGGUWqbWRX3GrVUxv/D6CGkPDcafZsyKdhyXvUjYIE2sLkDQNDi+lWbqHvmkBU 63QwDG61m8C2EOo+eWiXnQ==; Date: Sat, 04 Jan 2025 11:30:34 +0200 Message-Id: <867c7bexj9.fsf@gnu.org> From: Eli Zaretskii In-Reply-To: <86a5c7hqc4.fsf@gnu.org> (message from Eli Zaretskii on Fri, 03 Jan 2025 17:25:31 +0200) References: <000001db5ab4$06cec970$146c5c50$@0lock.xyz> <3gvOgDDbA00XBG4Xyu7q8lDJKQVYNo4pJ_Uzu35u0KNS8rhQ9PrenO2Kcz7GDHPNtUng9gnBpgPXtHMty_d_Bw==@protonmail.internalid> <86a5cdnfwc.fsf@gnu.org> <003001db5d81$a8f144b0$fad3ce10$@0lock.xyz> <87F91035-E0D9-4650-B332-10E4E8AD0AEF@0lock.xyz> <86ed1kghej.fsf@gnu.org> <000701db5dec$b8751ef0$295f5cd0$@0lock.xyz> <86a5c7hqc4.fsf@gnu.org> X-Spam-Score: -2.3 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > Cc: 75207@debbugs.gnu.org > Date: Fri, 03 Jan 2025 17:25:31 +0200 > From: Eli Zaretskii > > > I debugged a bit and it looks like w32_ansi_code_page is set to 1252 at some point. > > AFAICT, that happens when we load the pdumper file. > > > M-: w32-multibyte-code-page -> 0 > > M-: locale-coding-system -> cp65001 > > M-: file-name-coding-system -> nil > > M-: default-file-name-coding-system -> cp65001 > > OK, I think this confirms my hypothesis. I'll try to come up with a > patch, probably tomorrow. The patch is below, and it is for the master branch of the Emacs Git repository. > > > If I send you a C-level patch, are you able to build Emacs after patching it, > > > preferably the master branch of our Git repository? > > > > Sure. > > OK, but you'll need to build Emacs with a different system codepage to > see the effects of the fix. This still stands: to fully test the patch, please change your system codepage after building Emacs and then start Emacs and see if everything works as expected. diff --git a/src/emacs.c b/src/emacs.c index c1e0c9f..896f219 100644 --- a/src/emacs.c +++ b/src/emacs.c @@ -1419,7 +1419,18 @@ android_emacs_init (int argc, char **argv, char *dump_file) #ifdef HAVE_PDUMPER if (attempt_load_pdump) - initial_emacs_executable = load_pdump (argc, argv, dump_file); + { + initial_emacs_executable = load_pdump (argc, argv, dump_file); +#ifdef WINDOWSNT + /* Reinitialize the codepage for file names, needed to decode + non-ASCII file names during startup. This is needed because + loading the pdumper file above assigns to those variables values + from the dump stage, which might be incorrect, if dumping was done + on a different system. */ + if (dumped_with_pdumper_p ()) + w32_init_file_name_codepage (); +#endif + } #else ptrdiff_t bufsize; initial_emacs_executable = find_emacs_executable (argv[0], &bufsize); diff --git a/src/w32.c b/src/w32.c index a493991..deeca03 100644 --- a/src/w32.c +++ b/src/w32.c @@ -1685,6 +1685,19 @@ w32_init_file_name_codepage (void) { file_name_codepage = CP_ACP; w32_ansi_code_page = CP_ACP; +#ifdef HAVE_PDUMPER + /* If we were dumped with pdumper, this function will be called after + loading the pdumper file, and needs to reset the following + variables that come from the dump stage, which could be on a + different system with different default codepages. Then, the + correct value of w32-ansi-code-page will be assigned by + globals_of_w32fns, which is called from 'main'. Until that call + happens, w32-ansi-code-page will have the value of CP_ACP, which + stands for the default ANSI codepage. The other variables will be + computed by codepage_for_filenames below. */ + Vdefault_file_name_coding_system = Qnil; + Vfile_name_coding_system = Qnil; +#endif } /* Produce a Windows ANSI codepage suitable for encoding file names. From unknown Mon Aug 11 18:54:49 2025 X-Loop: help-debbugs@gnu.org Subject: bug#75207: Fwd: bug#75207: 29.4; Path conversion from native codepage to UTF-8 fails when Windows is set by default to UTF-8 Resent-From: michal@0lock.xyz Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 04 Jan 2025 17:47:07 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 75207 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 'Eli Zaretskii' Cc: 75207@debbugs.gnu.org Received: via spool by 75207-submit@debbugs.gnu.org id=B75207.173601278616305 (code B ref 75207); Sat, 04 Jan 2025 17:47:07 +0000 Received: (at 75207) by debbugs.gnu.org; 4 Jan 2025 17:46:26 +0000 Received: from localhost ([127.0.0.1]:57147 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tU8ED-0004Et-LZ for submit@debbugs.gnu.org; Sat, 04 Jan 2025 12:46:26 -0500 Received: from mail-4018.proton.ch ([185.70.40.18]:10339) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tU85q-0003nt-SG for 75207@debbugs.gnu.org; Sat, 04 Jan 2025 12:37:51 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=0lock.xyz; s=protonmail; t=1736012259; x=1736271459; bh=sQ2Pigy2dzQOMve1gkO0TjZ4bm/nBZrS3Jm1IHy54Pg=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector:List-Unsubscribe:List-Unsubscribe-Post; b=RiEICyMsiuqdWbEo4u06faNWrrGD3vPpOVyDYR2u2cyDnqXGYNDytVNxMK0poM582 r1RVOxj8iejnBgBCt+m+9l9hUnDPnG09U31jPiieyjOE4s36rqp5BPMy7yiDnDXdHI XhXl2dokt3DU941fW2weOl7RT577MveP6FJ62Vu/tQSi2CtVa0TeOqqs8AvRkddmbn 4bM0dEOkQRFervuK5Lpk9OvX8Gra1y54JHAzkaIXdBZHjs1mOxGZTGweMC1A309qZT mautWKwJwsWrkc2xNHq4ECQmickFdA1eMoakYwRLA770YN4qtkiK47SFUMCD39Tj8j +PaPzDpF7KUog== Date: Sat, 04 Jan 2025 17:37:34 +0000 From: michal@0lock.xyz Message-ID: <000301db5ecf$531a10e0$f94e32a0$@0lock.xyz> In-Reply-To: <867c7bexj9.fsf@gnu.org> References: <000001db5ab4$06cec970$146c5c50$@0lock.xyz> <3gvOgDDbA00XBG4Xyu7q8lDJKQVYNo4pJ_Uzu35u0KNS8rhQ9PrenO2Kcz7GDHPNtUng9gnBpgPXtHMty_d_Bw==@protonmail.internalid> <86a5cdnfwc.fsf@gnu.org> <003001db5d81$a8f144b0$fad3ce10$@0lock.xyz> <87F91035-E0D9-4650-B332-10E4E8AD0AEF@0lock.xyz> <86ed1kghej.fsf@gnu.org> <000701db5dec$b8751ef0$295f5cd0$@0lock.xyz> <86a5c7hqc4.fsf@gnu.org> <867c7bexj9.fsf@gnu.org> Feedback-ID: 123495485:user:proton X-Pm-Message-ID: 2d79e03a2d341a3b6d49a28d84ffc2258de57f07 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 2.5 (++) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: > This still stands: to fully test the patch, please change your system codepage > after building Emacs and then start Emacs and see if everything works as > expected. Done, looks like that fixed the issue :-). Content analysis details: (2.5 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 RCVD_IN_VALIDITY_SAFE_BLOCKED RBL: ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. [185.70.40.18 listed in sa-trusted.bondedsender.org] 0.0 RCVD_IN_VALIDITY_RPBL_BLOCKED RBL: ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. [185.70.40.18 listed in bl.score.senderscore.com] 0.0 RCVD_IN_MSPIKE_H3 RBL: Good reputation (+3) [185.70.40.18 listed in wl.mailspike.net] -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [185.70.40.18 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record -0.0 SPF_HELO_PASS SPF: HELO matches SPF record 2.0 PDS_OTHER_BAD_TLD Untrustworthy TLDs [URI: 0lock.xyz (xyz)] 0.0 RCVD_IN_MSPIKE_WL Mailspike good senders 0.5 FROM_SUSPICIOUS_NTLD From abused NTLD X-Mailman-Approved-At: Sat, 04 Jan 2025 12:46:21 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 2.5 (++) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: > This still stands: to fully test the patch, please change your system codepage > after building Emacs and then start Emacs and see if everything works as > expected. Done, looks like that fixed the issue :-). Content analysis details: (2.5 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [185.70.40.18 listed in list.dnswl.org] 0.0 RCVD_IN_VALIDITY_SAFE_BLOCKED RBL: ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. [185.70.40.18 listed in sa-accredit.habeas.com] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 RCVD_IN_VALIDITY_RPBL_BLOCKED RBL: ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. [185.70.40.18 listed in bl.score.senderscore.com] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record 2.0 PDS_OTHER_BAD_TLD Untrustworthy TLDs [URI: 0lock.xyz (xyz)] 0.0 RCVD_IN_MSPIKE_H3 RBL: Good reputation (+3) [185.70.40.18 listed in wl.mailspike.net] 0.0 RCVD_IN_MSPIKE_WL Mailspike good senders 0.5 FROM_SUSPICIOUS_NTLD From abused NTLD 1.0 BULK_RE_SUSP_NTLD Precedence bulk and RE: from a suspicious TLD -1.0 MAILING_LIST_MULTI Multiple indicators imply a widely-seen list manager > This still stands: to fully test the patch, please change your system cod= epage > after building Emacs and then start Emacs and see if everything works as > expected. Done, looks like that fixed the issue :-). Thank you for taking care of this and working on Emacs. Godspeed. From unknown Mon Aug 11 18:54:49 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: michal@0lock.xyz Subject: bug#75207: closed (Re: bug#75207: Fwd: bug#75207: 29.4; Path conversion from native codepage to UTF-8 fails when Windows is set by default to UTF-8) Message-ID: References: <861pxhby3v.fsf@gnu.org> <000001db5ab4$06cec970$146c5c50$@0lock.xyz> X-Gnu-PR-Message: they-closed 75207 X-Gnu-PR-Package: emacs Reply-To: 75207@debbugs.gnu.org Date: Sun, 05 Jan 2025 05:59:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1736056742-17032-1" This is a multi-part message in MIME format... ------------=_1736056742-17032-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #75207: 29.4; Path conversion from native codepage to UTF-8 fails when Wind= ows is set by default to UTF-8 which was filed against the emacs package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 75207@debbugs.gnu.org. --=20 75207: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D75207 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1736056742-17032-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 75207-done) by debbugs.gnu.org; 5 Jan 2025 05:58:56 +0000 Received: from localhost ([127.0.0.1]:59205 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tUJf6-0004QR-0a for submit@debbugs.gnu.org; Sun, 05 Jan 2025 00:58:56 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:46964) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tUJf3-0004QC-S1 for 75207-done@debbugs.gnu.org; Sun, 05 Jan 2025 00:58:54 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tUJey-0000TO-Bz; Sun, 05 Jan 2025 00:58:48 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=VQ17XvBnj2vEwbPzSGa21Qrbau0Bddq3EbVFQMLZblM=; b=I0FHmChPnYvB 57FEleg05NH+/Z8K+w6hQvm8/5llTg0gPSdI+e993AYr2K9ZAezPN/ZN0IEq63fW0QzzMyZQFoqbc o3progcF+QL6TAcTAXyOjSPowNtcaHGXn+Sq04ZuRky7KpVqUX9fISskXpfF7BxrYAWIyfyHh0bkg roEYa89k1HdbVDJhJjZwcMQtWHpei+9C627gNE/H74y2IeySka91Eo/g0PlelJMVQlAJfuOYRv+7c soKbXYHNxaGghgrvGNGb+L/bxN1uDe/UqScVRGF0SqWAawSsdtuW8uLZbHpeqgTet/M+u8UDnSYzw jjSzv/ds3LxGojsfxTrpAg==; Date: Sun, 05 Jan 2025 07:58:44 +0200 Message-Id: <861pxhby3v.fsf@gnu.org> From: Eli Zaretskii To: michal@0lock.xyz In-Reply-To: <000301db5ecf$531a10e0$f94e32a0$@0lock.xyz> (michal@0lock.xyz) Subject: Re: bug#75207: Fwd: bug#75207: 29.4; Path conversion from native codepage to UTF-8 fails when Windows is set by default to UTF-8 References: <000001db5ab4$06cec970$146c5c50$@0lock.xyz> <3gvOgDDbA00XBG4Xyu7q8lDJKQVYNo4pJ_Uzu35u0KNS8rhQ9PrenO2Kcz7GDHPNtUng9gnBpgPXtHMty_d_Bw==@protonmail.internalid> <86a5cdnfwc.fsf@gnu.org> <003001db5d81$a8f144b0$fad3ce10$@0lock.xyz> <87F91035-E0D9-4650-B332-10E4E8AD0AEF@0lock.xyz> <86ed1kghej.fsf@gnu.org> <000701db5dec$b8751ef0$295f5cd0$@0lock.xyz> <86a5c7hqc4.fsf@gnu.org> <867c7bexj9.fsf@gnu.org> <000301db5ecf$531a10e0$f94e32a0$@0lock.xyz> X-Spam-Score: -0.3 (/) X-Debbugs-Envelope-To: 75207-done Cc: 75207-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.3 (-) > Date: Sat, 04 Jan 2025 17:37:34 +0000 > From: michal@0lock.xyz > Cc: 75207@debbugs.gnu.org > > > This still stands: to fully test the patch, please change your system codepage > > after building Emacs and then start Emacs and see if everything works as > > expected. > > Done, looks like that fixed the issue :-). Thanks for testing, I therefore installed the changes on the master branch, and I'm closing this bug. ------------=_1736056742-17032-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 30 Dec 2024 18:29:54 +0000 Received: from localhost ([127.0.0.1]:59925 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tSKWV-0008JH-Va for submit@debbugs.gnu.org; Mon, 30 Dec 2024 13:29:54 -0500 Received: from lists.gnu.org ([209.51.188.17]:57782) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tSEd8-000605-19 for submit@debbugs.gnu.org; Mon, 30 Dec 2024 07:12:18 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tSEd7-00067d-R0 for bug-gnu-emacs@gnu.org; Mon, 30 Dec 2024 07:12:17 -0500 Received: from mail-4022.proton.ch ([185.70.40.22]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tSEd5-0003h0-1T for bug-gnu-emacs@gnu.org; Mon, 30 Dec 2024 07:12:17 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=0lock.xyz; s=protonmail; t=1735560725; x=1735819925; bh=ZvPWjQ/zAL73fSPc5zrZ9YyghnJJuMHTnvW6I5L42AU=; h=Date:To:From:Subject:Message-ID:Feedback-ID:From:To:Cc:Date: Subject:Reply-To:Feedback-ID:Message-ID:BIMI-Selector: List-Unsubscribe:List-Unsubscribe-Post; b=IGsHo5FUeKzXllS7N571DeW8jZZR8S2EUC4MkPtwpuA75A/VA8TNXffemtIjrV8zu 5EepGU16yo6MxWUFwl9IX6nxWJVDHlNroJ/v6sIXPxFT+nu5KjmNUzV46C28L5KEgT a9UUg2CTU2REpj01D+G2holBGaEAJ6O+q09XlL+3/MXsmD6yi4o4okbYNc8GD9nYjz S6Ca5vSxFD17iuToBnJs1nhtdcrmSA1/h+Z1CtC6XbBrhcBKduuQQGDwIk9DAz6zZk qafkESZ1E5llUTyomX5oy8fk+eCFMJj1Xi/H/Kta/K3/lWkv/ds8wPNF7pPg30S9PW Hfmjh4EOUeNAg== Date: Mon, 30 Dec 2024 12:12:02 +0000 To: bug-gnu-emacs@gnu.org From: michal@0lock.xyz Subject: 29.4; Path conversion from native codepage to UTF-8 fails when Windows is set by default to UTF-8 Message-ID: <000001db5ab4$06cec970$146c5c50$@0lock.xyz> Feedback-ID: 123495485:user:proton X-Pm-Message-ID: 3185ff365b2172afad6fad09e05542187796efc4 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=185.70.40.22; envelope-from=michal@0lock.xyz; helo=mail-4022.proton.ch X-Spam_score_int: 24 X-Spam_score: 2.4 X-Spam_bar: ++ X-Spam_report: (2.4 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FROM_SUSPICIOUS_NTLD=0.498, FROM_SUSPICIOUS_NTLD_FP=1.997, PDS_OTHER_BAD_TLD=1.997, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H4=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Mon, 30 Dec 2024 13:29:50 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) Emacs generates gibberish UTF-8 characters during conversion from native codepage to UTF-8 if experimental default UTF-8 codepage is set on Windows. In GNU Emacs 29.4 (build 2, x86_64-w64-mingw32) of 2024-07-05 built on AVALON Windowing system distributor 'Microsoft Corp.', version 10.0.22631 System Description: Microsoft Windows 10 Education (v10.0.2009.22631.4602) Configured using: 'configure --with-modules --without-dbus --with-native-compilation=3Daot --without-compress-install --with-sqlite3 --with-tree-sitter CFLAGS=3D-O2' Configured features: ACL GIF GMP GNUTLS HARFBUZZ JPEG JSON LCMS2 LIBXML2 MODULES NATIVE_COMP NOTIFY W32NOTIFY PDUMPER PNG RSVG SOUND SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER WEBP XPM ZLIB (NATIVE_COMP present but libgccjit not available) Important settings: value of $LANG: ENG locale-coding-system: cp65001 Major mode: recentf-dialog Minor modes in effect: global-company-mode: t company-mode: t nyan-mode: t fido-vertical-mode: t icomplete-vertical-mode: t icomplete-mode: t fido-mode: t global-display-line-numbers-mode: t display-line-numbers-mode: t recentf-mode: t global-display-fill-column-indicator-mode: t display-fill-column-indicator-mode: t tooltip-mode: t global-eldoc-mode: t show-paren-mode: t electric-indent-mode: t mouse-wheel-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t column-number-mode: t line-number-mode: t transient-mark-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t Load-path shadows: c:/Users/Micha=C5=82/.emacs.d/elpa/transient-20241102.1229/transient hides = c:/Program Files/Emacs/emacs-29.4/share/emacs/29.4/lisp/transient c:/Users/Micha=C5=82/.emacs.d/elpa/standard-themes-2.1.0/theme-loaddefs hid= es c:/Program Files/Emacs/emacs-29.4/share/emacs/29.4/lisp/theme-loaddefs Features: (shadow sort mail-extr emacsbug message yank-media puny dired dired-loaddefs rfc822 mml mml-sec epa epg rfc6068 epg-config gnus-util time-date mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils eldoc-box high-theme company-oddmuse company-keywords company-etags etags fileloop generator xref project company-gtags company-dabbrev-code company-dabbrev company-files company-clang company-capf company-cmake company-semantic company-template company-bbdb company nyan-mode icomplete display-line-numbers recentf tree-widget wid-edit easy-mmode display-fill-column-indicator jai-mode derived compile text-property-search comint ansi-osc ansi-color ring js c-ts-common treesit imenu cc-mode cc-fonts cc-guess cc-menus cc-cmds cc-styles cc-align cc-engine cc-vars cc-defs theme-switcher finder-inf almost-mono-themes-autoloads auctex-autoloads tex-site centered-window-autoloads cmake-mode-autoloads company-autoloads dtrt-indent-autoloads editorconfig-autoloads eldoc-box-autoloads erlang-autoloads exec-path-from-shell-autoloads go-mode-autoloads gruber-darker-theme-autoloads haskell-mode-autoloads highlight-symbol-autoloads latex-preview-pane-autoloads magit-autoloads pcase magit-section-autoloads dash-autoloads markdown-mode-autoloads merlin-autoloads multiple-cursors-autoloads nyan-mode-autoloads powershell-autoloads projectile-autoloads rg-autoloads rust-mode-autoloads slime-autoloads macrostep-autoloads solarized-theme-autoloads standard-themes-autoloads swift-mode-autoloads transient-autoloads tuareg-autoloads rx caml-autoloads wgrep-autoloads white-sand-theme-autoloads with-editor-autoloads info compat-autoloads yasnippet-autoloads zig-mode-autoloads reformatter-autoloads package browse-url url url-proxy url-privacy url-expand url-methods url-history url-cookie generate-lisp-file url-domsuf url-util mailcap url-handlers url-parse auth-source cl-seq eieio eieio-core cl-macs password-cache json subr-x map byte-opt gv bytecomp byte-compile url-vars cl-loaddefs cl-lib rmc iso-transl tooltip cconv eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode mwheel dos-w32 ls-lisp disp-table term/w32-win w32-win w32-vars term/common-win tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors frame minibuffer nadvice seq simple cl-generic indonesian philippine cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite emoji-zwj charscript charprop case-table epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button loaddefs theme-loaddefs faces cus-face macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget keymap hashtable-print-readable backquote threads w32notify w32 lcms2 multi-tty make-network-process native-compile emacs) Memory information: ((conses 16 185675 75051) (symbols 48 14661 7) (strings 32 55444 14585) (string-bytes 1 1821337) (vectors 16 27409) (vector-slots 8 520326 162526) (floats 8 83 1011) (intervals 56 494 150) (buffers 984 11)) ------------=_1736056742-17032-1--