Closed Bug 425620 Opened 17 years ago Closed 17 years ago

checksetup.pl doesn't pick up the user's language correctly

Categories

(Bugzilla :: Installation & Upgrading, defect)

3.1.3
All
Windows XP
defect
Not set
minor

Tracking

()

RESOLVED FIXED
Bugzilla 3.2

People

(Reporter: Wurblzap, Assigned: Wurblzap)

References

Details

Attachments

(1 file, 2 obsolete files)

This may be Windows-only: setlocale() may return strings in the form of German_Germany.1252. This is unsuitable because expects language codes (de_DE.1252 would be good instead).
Depends on: 425288
Attached patch Patch (obsolete) — Splinter Review
Fixes issue. This patch assumes the patch of bug 425288 to be applied.
Attached patch Patch 1.1 (obsolete) — Splinter Review
Attachment #312231 - Attachment is obsolete: true
Attachment #312688 - Flags: review?(LpSolit)
Comment on attachment 312688 [details] [diff] [review] Patch 1.1 >+use Locale::Language; This looks good (I didn't test as I don't have Windows in hands right now), but manpage of Locale::Language says: KNOWN BUGS AND LIMITATIONS · In the current implementation, all data is read in when the module is loaded, and then held in memory. A lazy implementation would be more memory friendly. So as we only need this module in get_console_locale() which is only called by checksetup.pl, i.e. is never used under normal Bugzilla usage, couldn't we remove this line and write "require Locale::Language" in get_console_locale() to not load it all the time? As Bugzilla::Install::Util is used by Bugzilla::Template, we would load it for all pages, which would eat useless memory. r=LpSolit with this small change (you will then have to explicitly call Locale::Language::language2code() or import this method first). Carry forward my r+ on the updated patch.
Attachment #312688 - Flags: review?(LpSolit) → review+
Holding approval till the patch is updated.
Flags: approval?
Attached patch Patch 1.1.1Splinter Review
Good idea. This patch does this. It works as well.
Attachment #312688 - Attachment is obsolete: true
Attachment #312729 - Flags: review+
Flags: approval? → approval+
Checking in Bugzilla/Install/Util.pm; /cvsroot/mozilla/webtools/bugzilla/Bugzilla/Install/Util.pm,v <-- Util.pm new revision: 1.13; previous revision: 1.12 done
Status: ASSIGNED → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: