playback/player/qt: Use QUrl::toEncoded() instead of ::toString()

The former properly encodes the URL components to give a valid URL, the
latter generates a human-readable URL.
This commit is contained in:
Simon Himmelbauer 2017-05-15 12:02:03 +03:00 committed by Sebastian Dröge
parent d909deaaf4
commit f7ce5cd694

View file

@ -495,7 +495,7 @@ void Player::onEndOfStreamReached(Player *player)
void Player::setUri(QUrl url) void Player::setUri(QUrl url)
{ {
Q_ASSERT(player_ != 0); Q_ASSERT(player_ != 0);
QByteArray uri = url.toString().toLocal8Bit(); QByteArray uri = url.toEncoded();
gst_player_set_uri(player_, uri.data()); gst_player_set_uri(player_, uri.data());