Stas Bekman wrote:
Ruslan U. Zakirov wrote:

Apache-2 form CVS as mp2.
Some locale/UTF issues?
I think it's not critical issue and I could force make install.

Verbose make test output:
t/apache/util....1..4
# Running under perl version 5.008003 for linux
# Current time local: Tue Mar 16 18:33:54 2004
# Current time GMT:   Tue Mar 16 15:33:54 2004
# Using Test.pm version 1.24
# testing : Apache::Util::ht_time($pool)
# expected: (?-xism:^\w\w\w, \d\d \w\w\w \d\d\d\d \d\d:\d\d:\d\d)
# received: ÐÑÐ, 16 ÐÐÑ 2004 15:33:57 GMT
not ok 1

[snip]

Hello, Stas.

Ouch, I thought that \w will match any letter, but I guess it won't w/o loading locale. Does the problem go away if you apply this patch?
Nop.
I've got absolutely same results. I have ru_RU.CP1251 locale. And output from Apache::Util::ht_time conform to this. I see right date in console.
I'v checked $fmtdate with Encode::is_utf8, it's not utf8 internal format in both cases. I never used a lot 'use locale' so don't know how exactly perl handle regexps in this case.


I have success with next tricky code:
$fmtdate = Apache::Util::ht_time($r->pool);
$fmtdate = Encode::decode('cp1251', $fmtdate);

Best regards. Ruslan.

[snip]

--
Report problems: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html
List etiquette: http://perl.apache.org/maillist/email-etiquette.html



Reply via email to