apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Branko Čibej <br...@xbc.nu>
Subject Re: Misbehaviour of apr_os_locale_encoding on Windows
Date Tue, 13 Apr 2010 19:29:23 GMT
On 13.04.2010 20:21, Роман Донченко wrote:
> Branko Čibej <brane@xbc.nu> писал в своём письме Tue, 13 Apr
> 23:34:21 +0500:
>> On 13.04.2010 19:19, William A. Rowe Jr. wrote:
>>> What is your opinion of the proposed patch to just this interface? 
>>> It seems
>>> that aligning to the system LCID is very problematic for a
>>> multi-user OS,
>>> where you are on an eastern European codepage, and I'm on a western
>>> codepage.
>>> The files you are working with are likely different than mine. 
>>> Changing to
>>> the systemwide codepage definitely seems invalid, notwithstanding
>>> the issues
>>> noted about apr_user_name_get().
>> I really have no clue offhand. It seems wrong to ignore the thread
>> locale in all cases. Like I wrote in the other post, this picking of one
>> of the 55 different current locales can probably only be properly done
>> by the application, not by APR. Which would imply that either APR should
>> expose some of those alternate locales through its API (eek!) or we
>> gently dump this whole issue as a Somebody Else's Problem.
> You mean My Problem, right? ;=]

No, I mean the application's problem, in this case, Subversion's.

> Anyway, we're not ignoring the whole thread locale here — just the
> code page part. And here's another thought experiment: Notepad, by
> default, saves and reads files in the system codepage, regardless of
> what the user locale says. Makes sense to be compatible with Notepad,
> doesn't it? 8=] That, and apr_user_name_get, and all the ANSI versions
> of the WinAPI functions - you'd be hard-pressed to find a place where
> the user locale's code page is actually used. Well, maybe in projects
> that use APR. 8=]

I was under the impression that Windows allowed each window of each
application to use a different input method and code page, hence the
assumption that the thread locale's code page is the correct one. Is
that not the case?

-- Brane

View raw message