#1348 MSYS returns the username in the wrong encoding

Cesar Strauss
Roman Donchenko

This is Windows XP, MSYS 1.0.11. The following is printed by the MSYS id.exe:

uid=500(?¤┐Ё-Ёбва вRа) gid=544(Администраторы) groups=544(Администраторы)

As you can see, the username is garbled. Redirecting to a file makes it clear that the output is in the system ANSI code page (1251), while the username (which is actually Администратор) is in the OEM code page (866).


  • Earnie Boyd
    Earnie Boyd

    • labels: MSYS --> locale, code page
    • status: open --> pending
    • assigned_to: Cesar Strauss
    • milestone: --> MSYS
    • type: --> Bug
    • resolution: --> none
    • category: --> Unknown
    • patch_attached: --> False
  • Earnie Boyd
    Earnie Boyd

    Cesar, what is the status of this issue?

  • davispuh

    there still exists such issue (but it's fixed for git-msys) and actually non-ANSI characters for windows console are nightmare, so much messed up...

    look at (click on screenshot for full size, half isn't visible here) screenshot

    There I've one folder with name in Chinese, file in Arabic and another folder with name which contains ā (this language I've in regional settings for non-unicode programs)
    To the left side I've git-msys and to right is just msys taken from newest installer.
    My Windows account name is Dāvis.

    Also when I open msys for first time it automatically creates home dir, but it's created Dvis (the correct folder name I created manually)

    here's more

    If I tap tab then I get correct list of filenames, but not with ls, also I can enter Dāvis dir with typing D?vis, but can't for others.

    and it's not specific to Windows 8 nor that I've localized windows interface.

    Windows cmd and even PowerShell also doesn't display Chinese nor Arabic but does display correctly ā, I think it's probably because console font doesn't support those characters.

    also in windows cmd I can type ā character and others, but in msys can't. There's loads of bugs, probably issues could be made for each of them. I didn't even mentioned all and these bugs have existed for years.

    Last edit: davispuh 2013-02-14