On Mon, 5 Jul 2004 16:51:32 +0000, Nuno Ricardo Gomes Antunes wrote
Hi,
I'm using OpenCA 0.9.2 RC5 under FreeBSD.
When I try to change the language, nothing happens.. No error and the languge stays the default English..
I think I found the cause of this.
At src/common/lib/functions/initServer's function setLanguage, we see something like this:
sub setLanguage { [...] setlocale(LC_MESSAGES, $LANGUAGE); [...] }
setlocale's argument $LANGUAGE is usualy something like "de_DE" or "pl_PL" (among others) but according to 'man 1 perllocale' it should be "de_DE.ISO8859-1" or "pl_PL.ISO8859-2" respectively (both FreeBSD 5.2.1 and Slackware 9.1 manpages pointed that way).
I tested changing this and now the all the translations of OpenCA work on FreeBSD. Tested also on Slackware 9.1 and it seems to work ok also..
I commited a fix for setLanguage. I have no problems - with an without the patch. This is the new version.
sub setLanguage { our $LANGUAGE = $_[0]; our $CHARSET = $_[1]; setlocale(LC_MESSAGES, $LANGUAGE.".".uc ($CHARSET)); textdomain("openca"); bindtextdomain("openca", $AUTOCONF{"lib_prefix"}."/locale"); bind_textdomain_codeset ("openca", $CHARSET); if (defined $log) { my $enc = $log->setEncoding ($CHARSET); debug ("initServer: setLanguage: setEncoding for log return $enc"); } $ui_html->setLanguage ($LANGUAGE, $CHARSET) if ($ui_html); }
Michael -- ------------------------------------------------------------------- Michael Bell Email: [EMAIL PROTECTED] ZE Computer- und Medienservice Tel.: +49 (0)30-2093 2482 (Computing Centre) Fax: +49 (0)30-2093 2704 Humboldt-University of Berlin Unter den Linden 6 10099 Berlin Email (private): [EMAIL PROTECTED] Germany http://www.openca.org
-------------------------------------------------------
This SF.Net email sponsored by Black Hat Briefings & Training.
Attend Black Hat Briefings & Training, Las Vegas July 24-29 - digital self defense, top technical experts, no vendor pitches, unmatched networking opportunities. Visit www.blackhat.com
_______________________________________________
OpenCA-Devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/openca-devel