phonon xine mediaobject and badly encoded filenames
Marcos Dione
mdione at grulic.org.ar
Mon Nov 9 23:20:58 CET 2009
On Mon, Nov 09, 2009 at 06:30:17PM +0100, Marcos Dione wrote:
> On Mon, Nov 09, 2009 at 04:56:14PM +0100, Matthias Kretz wrote:
> > this is a very delicate part of the code to touch. Xine MRLs have their own
> > non-standard way to do escaping because there are some characters used for
> > special purposes.
>
> any useful doc to read?
ok, from what I see in mrlEncode(), it doesn't linke anything not-ascii,
plus backslashes, percent signs and hashes (#). QUrl.toEncoded() handles all
but the last.
> > I don't recall from the top of my head which ones they are, but please test
>
> you mean:
>
> https://bugs.kde.org/show_bug.cgi?id=172242
>
> I also found:
>
> https://bugs.kde.org/show_bug.cgi?id=197252
> https://bugs.kde.org/show_bug.cgi?id=206085
> https://bugs.kde.org/show_bug.cgi?id=173789
> https://bugs.kde.org/show_bug.cgi?id=189898
> https://bugs.kde.org/show_bug.cgi?id=190885
> https://bugs.kde.org/show_bug.cgi?id=194889
>
> and several other dupes and such.
>
> > that the following type of URLs still work with your patch:
> >
> > file://path/somethingwitha#.ogg
> > http://example.com/foo.ogg
> >
> > I think both will break - the first because of the missing MRL escaping, the
> > second because you prepend "file:/".
>
> ok, I will try to fix it so those play. it makes sense to use a QUrl
> instead of QFile/QString, but then we sould call mrlEncode with
> source.url().toEncoded() and fix from there.
...which is exactly what this patch does. mrlEncode() only handles the #
case. also, the 'file:/' is appended only if the QUrl has no scheme(), which is
the only case in we should add the scheme. anyways, it's a preview; I still
want to test it with filenames mentioned in those other bug reports. I will do
that tomorrow night.
--
(Not so) Random fortune:
¿Por qué el software libre es democrático? Porque el usuario decide las
funciones que éste tendrá y no son impuestas de manera dictatorial por
una empresa desarrolladora a la cual le pagamos. Porque al ser
comunitario, la comunidad entera elige el destino de dicho software.
-- Richard Stallman
-------------- next part --------------
A non-text attachment was scrubbed...
Name: phonon-xine_backend-broken_encoding_paths.diff
Type: text/x-diff
Size: 1384 bytes
Desc: not available
Url : http://mail.kde.org/pipermail/phonon-backends/attachments/20091109/ebbc9b5e/attachment.bin
More information about the Phonon-backends
mailing list