Persona is no longer an option for authentication on BMO. For more details see Persona Deprecated.
Last Comment Bug 3867 - Locale- nsIWin32Locale.GetPlatformLocale deos not return correct LCID
: Locale- nsIWin32Locale.GetPlatformLocale deos not return correct LCID
Product: MailNews Core
Classification: Components
Component: Internationalization (show other bugs)
: Trunk
: x86 Windows NT
: P3 normal (vote)
: M4
Assigned To: tague
: Katsuhiko Momoi
Depends on:
  Show dependency treegraph
Reported: 1999-03-16 16:22 PST by nhottanscp
Modified: 2008-07-31 01:22 PDT (History)
2 users (show)
See Also:
Crash Signature:
QA Whiteboard:
Iteration: ---
Points: ---


Description nhottanscp 1999-03-16 16:22:26 PST
GetPlatformLocale does not return a correct LCID. LCID for "en-US" is 1033 but I
am getting 54. Looks like it's just returning the first entry of the
table. No country table is used, this is also a problem.
Comment 1 tague 1999-04-06 11:30:59 PDT
Fixed.  Checked in 3/5/98.
Comment 2 nhottanscp 1999-04-07 10:26:59 PDT
I verified it's working for en-US, en-GB, fr-FR, de-DE and ja-JP.

Can this also support locale to charset name mapping or it's someone else's
E.g. en_US -> iso-8859-1
I need this for the conversion in order to talk to non unicode API.
Comment 3 Katsuhiko Momoi 1999-04-09 01:17:59 PDT
** Checked with 4/8/99 evening Win32 build **

Following nhotta's 4/7/99 comment, I'll be marking this fix verified.
LocaleSelfTest.exe does include self-test mechanism for several locales
mentioned in nhotta's comment. (Try 'LocaleSelfTest -v'.)

The values obtained by the selft tests are:

en_US = 0x0409
en_GB = 0x0809
fr_FR = 0x040c
de_DE = 0x0407
ja_JP = 0x0411

These are all correct Win32 Locale ID hex values.

Given these results, it's safe to assume that GetPlatformLocale is
returning correct values for given locales.
Comment 4 Katsuhiko Momoi 1999-04-09 01:21:59 PDT
The source for LocaleSelfTest can be viewed here:

Check out the source files from this directory:

Comment 5 tague 1999-04-09 12:18:59 PDT
happy.  if you want a more direct verification, you can run nsLocaleTest - of
course since i wrote it it might be biased :)

Note You need to log in before you can comment on or make changes to this bug.