Bug 20667

Summary: Locale-aware functions cause problems
Product: xorg Reporter: Fatih Aşıcı <fatih>
Component: Server/GeneralAssignee: Xorg Project Team <xorg-team>
Status: RESOLVED INVALID QA Contact: Xorg Project Team <xorg-team>
Severity: normal    
Priority: medium    
Version: unspecified   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:

Description Fatih Aşıcı 2009-03-14 18:10:16 UTC
There are some places using the following locale-aware functions:

tolower
toupper
islower
isupper

In Turkish, lower case of 'I' letter is not 'i'. This causes serious problems in xserver. e.g. While xserver starts with the followine line:

BusId "pci:0:2:0"

it gives an error with the following:

BusId "PCI:0:2:0"

Because xserver converts PCI to pcı in tr_TR.UTF-8 locale.
Comment 1 Alan Coopersmith 2009-03-16 17:03:46 UTC
Are these functions using the locale even though Xorg never calls setlocale()?

According to the setlocale() documentation, the locale should be "C" or "POSIX",
using only ASCII characters, if setlocale() is not called.
Comment 2 Fatih Aşıcı 2009-03-16 19:26:04 UTC
You are right. Server does not call setlocale; but vboxmouse module does. After this module is loaded the locale changes. I will report this to VirtualBox developers.

Thanks.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.