Web lists-archives.com

Re: [MPlayer-dev-eng] [PATCH]can not open ISO file including multibyte file path. on Windows.




On Mon, Mar 06, 2017 at 04:56:02AM +0900, Tadashi Ando wrote:
> Hi All.
> I'm Ando from Japan.
> I found bug, and fixed it.
> Bug is relating to multibyte. And relating to DVD .ISO.
> 
> DVDOpen() of MPlayer of Windows version requires
> ANSI multibyte path as argument.
> But current MPlayer using UTF-8.
> ( UTF-8 is internal encoding of MPlayer )
> Therefore, If .ISO file path is including multibyte,
> DVDOpen() ( with libdvdread & libdvdcss ) can't open file.
> And MPlayer can't play .ISO file.
> 
> My patch is, convert UTF-8 to ANSI when using DVDOpen().

I think you are actually converting from UTF-8 to the local
8-bit code-page (which usually isn't actually ANSI).
It also means that while it's an improvement, it won't be
able to open files where the filename cannot be represented
in the local code-page.
IMO a "proper" solution would be to make DVDOpen support UTF-8
file names, or alternatively add a new DVDOpen variant that support
wchar_t input (then the stream_file code should be possible to
reuse).
Another option would be to pick the 8.3 compatibility file name
if we cannot represent the real name in the local code page.
It is a bit risky, since the 8.3 name will probably got away
at some point.
_______________________________________________
MPlayer-dev-eng mailing list
MPlayer-dev-eng@xxxxxxxxxxxx
https://lists.mplayerhq.hu/mailman/listinfo/mplayer-dev-eng