[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gnump3d-devel] how to pass... (forgotten attach)
From: |
Vasily i. Redkin |
Subject: |
[Gnump3d-devel] how to pass... (forgotten attach) |
Date: |
Thu, 31 May 2007 13:49:13 +0400 |
User-agent: |
Icedove 1.5.0.10 (X11/20070329) |
Sorry, missed attach in prev. post.
--
vir icq:9326537
--- /usr/share/perl5/gnump3d/mp3info.pm.bak 2007-05-31 13:12:21.601415774
+0400
+++ /usr/share/perl5/gnump3d/mp3info.pm 2007-05-31 13:14:35.034512228 +0400
@@ -167,6 +167,7 @@
my $unicode_module = eval { require Encode; require Encode::Guess };
my $UNICODE = use_mp3_utf8($unicode_module ? 1 : 0);
+my $id3encoding='cp1251';
sub use_mp3_utf8 {
my($val) = @_;
@@ -502,6 +503,9 @@
if ($UNICODE) {
for my $key (keys %info) {
next unless $info{$key};
+ if ($id3encoding) {
+ $info{$key} =
Encode::decode($id3encoding, $info{$key});
+ }
$info{$key} =
Encode::encode_utf8($info{$key});
}
}
@@ -582,8 +586,9 @@
$data =
Encode::decode('utf8', $data);
} elsif ($encoding eq
"\000") {
# Try and guess
the encoding, otherwise just use latin1
- my $dec =
Encode::Guess->guess($data);
- if (ref $dec) {
+
if($id3encoding) {
+ $data =
Encode::decode($id3encoding, $data);
+ } elsif(ref(my
$dec = Encode::Guess->guess($data))) {
$data =
$dec->decode($data);
} else {
# Best
try
smime.p7s
Description: S/MIME Cryptographic Signature
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Gnump3d-devel] how to pass... (forgotten attach),
Vasily i. Redkin <=