Bugzilla – Bug 1774
Browse music folders does not show special characters
Last modified: 2011-03-16 04:19:51 UTC
Current test on Linux - DE - iso-8859-1 Accented characters display correctly in the lists: I can open the "Am�lie Poulain" folder, songs are correctly shown. But the top link "Home/Music folder/Am,lie Poulain" or the top line on the player don't show the accents (dito for Bj�rk, Ohrew�rm et al., of course) When, on the player, I go into the song details, everything's fine again, even the top line. Using the file.ext format on the player would not display accented characters in the normal browse mode, though they do in BMF. Normal genre/album/artist browse in the web interface is ok. While browsing these folders I get quite a few of the following errors: Malformed UTF-8 character (unexpected non-continuation byte 0x6c, immediately after start byte 0xe9) in substitution (s///) at /home/mh/eclipse/SVN/Slim/Display/Display.pm line 55. Malformed UTF-8 character (unexpected non-continuation byte 0x6c, immediately after start byte 0xe9) in substitution (s///) at /home/mh/eclipse/SVN/Slim/Display/Display.pm line 84.
Michael - is this with perl 5.6 or perl 5.8 ?
5.8.5 on Mandrake 10.1 and 5.8.6 on DSL/Knoppix/Debian. I don't use 5.6.x for slimserver any more.
Created attachment 627 [details] correctly display special characters Possible fix for correct encoding in BMF mode.
Michael - if this works for you, go ahead and check it in. Looks good from here.
Hmm.. that doesn't work for me. The top line is messed up in the web ui
And you're using utf8 on your system? Do we have to guess/check this before disabling utf8? I've seen similar things in other parts of the code.
Michael - can you add this addition, and see if it works for your system? Index: Slim/Utils/Misc.pm =============================================================== ==== --- Slim/Utils/Misc.pm (revision 3684) +++ Slim/Utils/Misc.pm (working copy) @@ -309,7 +309,7 @@ sub utf8off { my $string = shift; - if ($string && $] > 5.007) { + if ($string && $] > 5.007 && looks_like_utf8($string)) { Encode::_utf8_off($string); }
I'm afraid, it does not, neither with nor without my patch.
Ok - can you add in "sub utf8off": use Devel::Peek; print Dump($string) and send me the output of one of the busted strings? Thanks
SV = PV(0x9947cd4) at 0x8954a4c REFCNT = 1 FLAGS = (PADBUSY,PADMY,POK,pPOK,UTF8) PV = 0xa7efe40 "Am\351lie Poulain - Le Fabuleux Destin d'Am\351lie Poulain"\0Malformed UTF-8 character (unexpected non-continuation byte 0x6c, immediately after st art byte 0xe9) in subroutine entry at /ramdisk/opt/slimserver/Slim/Utils/Misc.pm line 313. Malformed UTF-8 character (unexpected non-continuation byte 0x6c, immediately after start byte 0xe9) in subroutine entry at /ramdisk/opt/slimserver/Slim/Utils/Misc.p m line 313. [UTF8 "Am\x{0}e Poulain - Le Fabuleux Destin d'Am\x{0}e Poulain"] CUR = 52 LEN = 53 Malformed UTF-8 character (unexpected non-continuation byte 0x6c, immediately after start byte 0xe9) in pattern match (m//) at /ramdisk/opt/slimserver/Slim/Utils/Misc.pm line 343. (tons of that last one)
Michael - pushing this off to post 6.1
Michael - is this still an issue with the 6.2 trunk code?
Wow... updated my SVN copy for the first time in about two weeks (am/was on a vacation) - more than 130 files updated! I don't know which of your many changes did the trick but it's fine now. BMF on the player as in the web interface does show the umlauts and accents. Thanks a lot! I'll mark as fixed.