Fix urls in widgets being double encoded

See https://bugreports.qt.io/browse/QTBUG-110446
pull/1635/head
Nicolas Werner 12 months ago
parent ed6abe989f
commit b4afeada58
No known key found for this signature in database
GPG Key ID: C8D75E610773F2D9
  1. 4
      src/timeline/TimelineModel.cpp

@ -3282,7 +3282,9 @@ TimelineModel::widgetLinks() const
// compat with some widgets, i.e. FOSDEM // compat with some widgets, i.e. FOSDEM
url.replace("$theme", theme); url.replace("$theme", theme);
url = QUrl::toPercentEncoding(url, "/:@?#&=%"); // See https://bugreports.qt.io/browse/QTBUG-110446
// We want to make sure that urls are encoded, even if the source is untrustworthy.
url = QUrl(url).toEncoded();
list.push_back( list.push_back(
QLatin1String("<a href='%1'>%2</a>") QLatin1String("<a href='%1'>%2</a>")

Loading…
Cancel
Save