Comment 18 for bug 1449790

Revision history for this message
James Henstridge (jamesh) wrote :

'#' and '?' are reserved URI characters, used as separators for the query and fragment components respectively. So a URI like "file:///Mystify#.flac" is correctly parsed as having a path component of "/Mystify" and fragment component ".flac".

If music-app is producing URIs containing these characters but intending them to be part of the path component, then that is an error. If you want to convert between URLs and file names, Qt provides QUrl::toLocalFile and QUrl::fromLocalFile methods. These will take care of the necessary escaping. They don't seem to be exposed on the QML URL type though, so would probably need a C++ plugin to expose.

If music-app still has the URIs provided by mediascanner, they should also be well formed with correct escaping.