diff options
Diffstat (limited to 'debian/patches/make_rules_for_redirect_stricter.patch')
-rw-r--r-- | debian/patches/make_rules_for_redirect_stricter.patch | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/debian/patches/make_rules_for_redirect_stricter.patch b/debian/patches/make_rules_for_redirect_stricter.patch new file mode 100644 index 0000000..3622927 --- /dev/null +++ b/debian/patches/make_rules_for_redirect_stricter.patch @@ -0,0 +1,32 @@ +From 8ca687050b2c9789724df2cf9955d7ad7dd2c060 Mon Sep 17 00:00:00 2001 +From: Richard Moore <rich@kde.org> +Date: Mon, 19 Nov 2012 20:48:39 +0000 +Subject: [PATCH] Make the rules for redirects a bit stricter. + +Change-Id: I7a3cec664aa028202de3d3bda9f499e4deb2998d +--- + src/declarative/qml/qdeclarativexmlhttprequest.cpp | 8 +++++--- + 1 file changed, 5 insertions(+), 3 deletions(-) + +diff --git a/src/declarative/qml/qdeclarativexmlhttprequest.cpp b/src/declarative/qml/qdeclarativexmlhttprequest.cpp +index 5378a15..3de89a5 100644 +--- a/src/declarative/qml/qdeclarativexmlhttprequest.cpp ++++ b/src/declarative/qml/qdeclarativexmlhttprequest.cpp +@@ -1272,9 +1272,11 @@ void QDeclarativeXMLHttpRequest::finished() + QVariant redirect = m_network->attribute(QNetworkRequest::RedirectionTargetAttribute); + if (redirect.isValid()) { + QUrl url = m_network->url().resolved(redirect.toUrl()); +- destroyNetwork(); +- requestFromUrl(url); +- return; ++ if (url.scheme().toLower() != QLatin1String("file")) { ++ destroyNetwork(); ++ requestFromUrl(url); ++ return; ++ } + } + } + +-- +1.7.10.4 + |