kdirshare: percentage-encode the path reference

fixes loading of files that are percentage encoded and have to be
double-percentage encoded for browsers to cope with

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
Ivailo Monev 2023-06-25 03:45:50 +03:00
parent d57eb2ce29
commit cdb188800e

View file

@ -118,7 +118,7 @@ static QByteArray contentForDirectory(const QString &path, const QString &basedi
// qDebug() << Q_FUNC_INFO << fullpath << basedir << cleanpath;
data.append(" <td><a href=\"");
data.append(cleanpath.toUtf8());
data.append(QUrl::toPercentEncoding(cleanpath));
data.append("\">");
data.append(fileinfo.fileName().toUtf8());
data.append("</a><br></td>\n");