GNU bug report logs - #50266
28.0.50; expand-file-name broken with non ASCII characters

Previous Next

Package: emacs;

Reported by: Joakim Hårsman <joakim.harsman <at> gmail.com>

Date: Mon, 30 Aug 2021 12:09:01 UTC

Severity: normal

Tags: fixed

Found in version 28.0.50

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 50266 in the body.
You can then email your comments to 50266 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#50266; Package emacs. (Mon, 30 Aug 2021 12:09:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to Joakim Hårsman <joakim.harsman <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Mon, 30 Aug 2021 12:09:01 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Joakim Hårsman <joakim.harsman <at> gmail.com>
To: bug-gnu-emacs <bug-gnu-emacs <at> gnu.org>
Subject: 28.0.50; expand-file-name broken with non ASCII characters
Date: Mon, 30 Aug 2021 14:08:29 +0200
[Message part 1 (text/plain, inline)]
Bug manifests on Windows 10 ( I haven't tested other versions). Before
starting emacs:

C:\Users\JoakimHårsman>chdir
C:\Users\JoakimHårsman

C:\Users\JoakimHårsman>echo %HOME%
C:\users\JoakimHårsman

C:\Users\JoakimHårsman> runemacs -Q

Notice that the current directory which is the same as the HOME
environment, contains the letter å. After starting emacs with runemacs
-Q:

(expand-file-name default-directory)

returns

"c:/users/JoakimH  rsman/"

or alternatively

"c:/users/JoakimH\303\245rsman/"

while the correct return value should be

"c:/users/JoakimHårsman/"


In GNU Emacs 28.0.50 (build 1, x86_64-w64-mingw32)
Repository revision: 7640f1da0be206a7598c96acdfdaaf390a2b546c
Repository branch: master
Windowing system distributor 'Microsoft Corp.', version 10.0.19043
System Description: Microsoft Windows 10 Pro (v10.0.2009.19043.1165)

Configured using:
 'configure --prefix=/d/a/emacs-build/emacs-build/pkg/master-x86_64
 --with-native-compilation --with-zlib --with-gnutls --with-xml2
 --with-lcms2 --with-json --with-harfbuzz --without-cairo --with-rsvg
 --with-png --with-gif --without-tiff --with-jpeg --with-xpm
 --disable-build-details --disable-silent-rules --without-dbus
 --without-compress-install'

Configured features:
ACL GIF GMP GNUTLS HARFBUZZ JPEG JSON LCMS2 LIBXML2 MODULES NATIVE_COMP
NOTIFY W32NOTIFY PDUMPER PNG RSVG SOUND THREADS TOOLKIT_SCROLL_BARS XPM
ZLIB

Important settings:
  value of $LANG: en_US.UTF8
  locale-coding-system: cp1252

Major mode: Lisp Interaction

Minor modes in effect:
  tooltip-mode: t
  global-eldoc-mode: t
  eldoc-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  indent-tabs-mode: t
  transient-mark-mode: t

Load-path shadows:
None found.

Features:
(shadow sort mail-extr emacsbug message rmc puny dired dired-loaddefs
rfc822 mml mml-sec epa derived epg epg-config gnus-util rmail
rmail-loaddefs auth-source eieio eieio-core eieio-loaddefs
password-cache json map text-property-search time-date mm-decode
mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader
sendmail comp comp-cstr warnings subr-x rx cl-seq cl-macs cl-extra
help-mode seq byte-opt gv cl-loaddefs cl-lib bytecomp byte-compile cconv
rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils iso-transl
tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-float-type
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 elisp-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 cl-generic 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 charscript charprop case-table epa-hook
jka-cmpr-hook help simple abbrev obarray cl-preloaded nadvice button
loaddefs faces cus-face macroexp files window text-properties overlay
sha1 md5 base64 format env code-pages mule custom widget
hashtable-print-readable backquote threads w32notify w32 lcms2 multi-tty
make-network-process native-compile emacs)

Memory information:
((conses 16 89375 14408)
 (symbols 48 7898 1)
 (strings 32 22918 3463)
 (string-bytes 1 759569)
 (vectors 16 23743)
 (vector-slots 8 1091049 147200)
 (floats 8 29 266)
 (intervals 56 257 0)
 (buffers 992 12))
[Message part 2 (text/html, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#50266; Package emacs. (Mon, 30 Aug 2021 12:29:02 GMT) Full text and rfc822 format available.

Message #8 received at 50266 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Joakim Hårsman <joakim.harsman <at> gmail.com>
Cc: 50266 <at> debbugs.gnu.org
Subject: Re: bug#50266: 28.0.50;
 expand-file-name broken with non ASCII characters
Date: Mon, 30 Aug 2021 15:27:50 +0300
> From: Joakim Hårsman <joakim.harsman <at> gmail.com>
> Date: Mon, 30 Aug 2021 14:08:29 +0200
> 
> Bug manifests on Windows 10 ( I haven't tested other versions). Before starting emacs:
> 
> C:\Users\JoakimHårsman>chdir
> C:\Users\JoakimHårsman
> 
> C:\Users\JoakimHårsman>echo %HOME%
> C:\users\JoakimHårsman
> 
> C:\Users\JoakimHårsman> runemacs -Q
> 
> Notice that the current directory which is the same as the HOME
> environment, contains the letter å. After starting emacs with runemacs
> -Q:
> 
> (expand-file-name default-directory)
> 
> returns
> 
> "c:/users/JoakimH  rsman/"
> 
> or alternatively
> 
> "c:/users/JoakimH\303\245rsman/"

Is this limited to starting via runemacs, or starting "emacs -Q"
produces the same problem?

Thanks.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#50266; Package emacs. (Mon, 30 Aug 2021 13:42:02 GMT) Full text and rfc822 format available.

Message #11 received at 50266 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Joakim Hårsman <joakim.harsman <at> gmail.com>
Cc: 50266 <at> debbugs.gnu.org
Subject: Re: bug#50266: 28.0.50;
 expand-file-name broken with non ASCII characters
Date: Mon, 30 Aug 2021 16:41:04 +0300
[Please use Reply All to keep the bug address on the CC list.]

> From: Joakim Hårsman <joakim.harsman <at> gmail.com>
> Date: Mon, 30 Aug 2021 15:36:06 +0200
> 
> No wait, scratch that. Emacs -Q has the same error. I accidentally started 27.2 where it works.
> 
> On Mon, 30 Aug 2021 at 15:34, Joakim Hårsman <joakim.harsman <at> gmail.com> wrote:
> 
>  emacs -Q works and returns the correct file name.

OK, thanks.  I guess we don't decode the file name somewhere.  Hmm...




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#50266; Package emacs. (Thu, 02 Sep 2021 15:51:02 GMT) Full text and rfc822 format available.

Message #14 received at 50266 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: joakim.harsman <at> gmail.com
Cc: 50266 <at> debbugs.gnu.org
Subject: Re: bug#50266: 28.0.50;
 expand-file-name broken with non ASCII characters
Date: Thu, 02 Sep 2021 18:50:28 +0300
> Date: Mon, 30 Aug 2021 16:41:04 +0300
> From: Eli Zaretskii <eliz <at> gnu.org>
> Cc: 50266 <at> debbugs.gnu.org
> 
> > From: Joakim Hårsman <joakim.harsman <at> gmail.com>
> > Date: Mon, 30 Aug 2021 15:36:06 +0200
> > 
> > No wait, scratch that. Emacs -Q has the same error. I accidentally started 27.2 where it works.
> > 
> > On Mon, 30 Aug 2021 at 15:34, Joakim Hårsman <joakim.harsman <at> gmail.com> wrote:
> > 
> >  emacs -Q works and returns the correct file name.
> 
> OK, thanks.  I guess we don't decode the file name somewhere.  Hmm...

Please try the latest master branch, I hope I fixed this.




Added tag(s) fixed. Request was from Stefan Kangas <stefan <at> marxist.se> to control <at> debbugs.gnu.org. (Sat, 04 Sep 2021 07:01:06 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#50266; Package emacs. (Thu, 09 Sep 2021 17:19:02 GMT) Full text and rfc822 format available.

Message #19 received at 50266 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: joakim.harsman <at> gmail.com
Cc: 50266 <at> debbugs.gnu.org
Subject: Re: bug#50266: 28.0.50;
 expand-file-name broken with non ASCII characters
Date: Thu, 09 Sep 2021 20:18:41 +0300
Ping!  Did you have time to try the fixed code now in the master
branch?

> Resent-From: Eli Zaretskii <eliz <at> gnu.org>
> Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
> Resent-CC: bug-gnu-emacs <at> gnu.org
> Resent-Sender: help-debbugs <at> gnu.org
> Date: Thu, 02 Sep 2021 18:50:28 +0300
> From: Eli Zaretskii <eliz <at> gnu.org>
> Cc: 50266 <at> debbugs.gnu.org
> 
> > Date: Mon, 30 Aug 2021 16:41:04 +0300
> > From: Eli Zaretskii <eliz <at> gnu.org>
> > Cc: 50266 <at> debbugs.gnu.org
> > 
> > > From: Joakim Hårsman <joakim.harsman <at> gmail.com>
> > > Date: Mon, 30 Aug 2021 15:36:06 +0200
> > > 
> > > No wait, scratch that. Emacs -Q has the same error. I accidentally started 27.2 where it works.
> > > 
> > > On Mon, 30 Aug 2021 at 15:34, Joakim Hårsman <joakim.harsman <at> gmail.com> wrote:
> > > 
> > >  emacs -Q works and returns the correct file name.
> > 
> > OK, thanks.  I guess we don't decode the file name somewhere.  Hmm...
> 
> Please try the latest master branch, I hope I fixed this.
> 
> 
> 
> 




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#50266; Package emacs. (Sat, 11 Sep 2021 10:43:01 GMT) Full text and rfc822 format available.

Message #22 received at 50266 <at> debbugs.gnu.org (full text, mbox):

From: Joakim Hårsman <joakim.harsman <at> gmail.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 50266 <at> debbugs.gnu.org
Subject: Re: bug#50266: 28.0.50;
 expand-file-name broken with non ASCII characters
Date: Sat, 11 Sep 2021 12:41:58 +0200
[Message part 1 (text/plain, inline)]
Sorry, I haven’t had the time to do a build and try your fix yet. Last time
I used a snapshot someone  else built, so I have to install all the build
tools first.

tors 9 sep. 2021 kl. 19:18 skrev Eli Zaretskii <eliz <at> gnu.org>:

> Ping!  Did you have time to try the fixed code now in the master
> branch?
>
> > Resent-From: Eli Zaretskii <eliz <at> gnu.org>
> > Original-Sender: "Debbugs-submit" <
> debbugs-submit-bounces <at> debbugs.gnu.org>
> > Resent-CC: bug-gnu-emacs <at> gnu.org
> > Resent-Sender: help-debbugs <at> gnu.org
> > Date: Thu, 02 Sep 2021 18:50:28 +0300
> > From: Eli Zaretskii <eliz <at> gnu.org>
> > Cc: 50266 <at> debbugs.gnu.org
> >
> > > Date: Mon, 30 Aug 2021 16:41:04 +0300
> > > From: Eli Zaretskii <eliz <at> gnu.org>
> > > Cc: 50266 <at> debbugs.gnu.org
> > >
> > > > From: Joakim Hårsman <joakim.harsman <at> gmail.com>
> > > > Date: Mon, 30 Aug 2021 15:36:06 +0200
> > > >
> > > > No wait, scratch that. Emacs -Q has the same error. I accidentally
> started 27.2 where it works.
> > > >
> > > > On Mon, 30 Aug 2021 at 15:34, Joakim Hårsman <
> joakim.harsman <at> gmail.com> wrote:
> > > >
> > > >  emacs -Q works and returns the correct file name.
> > >
> > > OK, thanks.  I guess we don't decode the file name somewhere.  Hmm...
> >
> > Please try the latest master branch, I hope I fixed this.
> >
> >
> >
> >
>
[Message part 2 (text/html, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#50266; Package emacs. (Sat, 11 Sep 2021 11:45:02 GMT) Full text and rfc822 format available.

Message #25 received at 50266 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Joakim Hårsman <joakim.harsman <at> gmail.com>
Cc: 50266 <at> debbugs.gnu.org
Subject: Re: bug#50266: 28.0.50;
 expand-file-name broken with non ASCII characters
Date: Sat, 11 Sep 2021 14:44:23 +0300
> From: Joakim Hårsman <joakim.harsman <at> gmail.com>
> Date: Sat, 11 Sep 2021 12:41:58 +0200
> Cc: 50266 <at> debbugs.gnu.org
> 
> Sorry, I haven’t had the time to do a build and try your fix yet. Last time I used a snapshot someone  else
> built, so I have to install all the build tools first. 

OK, take your time, and thanks.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#50266; Package emacs. (Tue, 05 Oct 2021 13:38:02 GMT) Full text and rfc822 format available.

Message #28 received at 50266 <at> debbugs.gnu.org (full text, mbox):

From: Joakim Hårsman <joakim.harsman <at> gmail.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 50266 <at> debbugs.gnu.org
Subject: Re: bug#50266: 28.0.50;
 expand-file-name broken with non ASCII characters
Date: Tue, 5 Oct 2021 15:36:47 +0200
[Message part 1 (text/plain, inline)]
I finally had the time to try this and with the latest snapshot everything
works! Sorry for the delay in testing and thanks for the prompt fix.

Here's the version I tested with if it matters:

In GNU Emacs 29.0.50 (build 1, x86_64-w64-mingw32)
Repository revision: 44c13eefe8d30841000a96d82f467fb8d222e365
Repository branch: master
Windowing system distributor 'Microsoft Corp.', version 10.0.19043
System Description: Microsoft Windows 10 Pro (v10.0.2009.19043.1237)

Configured using:
 'configure --prefix=/d/a/emacs-build/emacs-build/pkg/master-x86_64
 CFLAGS=-O2 --with-native-compilation --with-zlib --with-gnutls
 --with-xml2 --with-lcms2 --with-json --with-harfbuzz --without-cairo
 --with-rsvg --with-png --with-gif --without-tiff --with-jpeg --with-xpm
 --disable-build-details --without-dbus --without-compress-install'

Configured features:
ACL GIF GMP GNUTLS HARFBUZZ JPEG JSON LCMS2 LIBXML2 MODULES NATIVE_COMP
NOTIFY W32NOTIFY PDUMPER PNG RSVG SOUND THREADS TOOLKIT_SCROLL_BARS XPM
ZLIB

Important settings:
  value of $LC_ALL: en_US.UTF8
  value of $LANG: en_US.UTF8
  locale-coding-system: cp1252

On Sat, 11 Sept 2021 at 13:44, Eli Zaretskii <eliz <at> gnu.org> wrote:

> > From: Joakim Hårsman <joakim.harsman <at> gmail.com>
> > Date: Sat, 11 Sep 2021 12:41:58 +0200
> > Cc: 50266 <at> debbugs.gnu.org
> >
> > Sorry, I haven’t had the time to do a build and try your fix yet. Last
> time I used a snapshot someone  else
> > built, so I have to install all the build tools first.
>
> OK, take your time, and thanks.
>
[Message part 2 (text/html, inline)]

Reply sent to Eli Zaretskii <eliz <at> gnu.org>:
You have taken responsibility. (Tue, 05 Oct 2021 15:43:02 GMT) Full text and rfc822 format available.

Notification sent to Joakim Hårsman <joakim.harsman <at> gmail.com>:
bug acknowledged by developer. (Tue, 05 Oct 2021 15:43:02 GMT) Full text and rfc822 format available.

Message #33 received at 50266-done <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Joakim Hårsman <joakim.harsman <at> gmail.com>
Cc: 50266-done <at> debbugs.gnu.org
Subject: Re: bug#50266: 28.0.50;
 expand-file-name broken with non ASCII characters
Date: Tue, 05 Oct 2021 18:42:39 +0300
> From: Joakim Hårsman <joakim.harsman <at> gmail.com>
> Date: Tue, 5 Oct 2021 15:36:47 +0200
> Cc: 50266 <at> debbugs.gnu.org
> 
> I finally had the time to try this and with the latest snapshot everything works! Sorry for the delay in testing
> and thanks for the prompt fix.
> 
> Here's the version I tested with if it matters:
> 
> In GNU Emacs 29.0.50 (build 1, x86_64-w64-mingw32)
> Repository revision: 44c13eefe8d30841000a96d82f467fb8d222e365
> Repository branch: master
> Windowing system distributor 'Microsoft Corp.', version 10.0.19043
> System Description: Microsoft Windows 10 Pro (v10.0.2009.19043.1237)

Great, thanks for testing.  I'm therefore closing this bug.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 03 Nov 2021 11:24:06 GMT) Full text and rfc822 format available.

This bug report was last modified 2 years and 147 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.