summaryrefslogtreecommitdiffstats
path: root/src/corelib/io
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@intel.com>2016-12-16 18:52:18 -0800
committerThiago Macieira <thiago.macieira@intel.com>2016-12-28 12:43:50 +0000
commitdc6b73390b262b9554599cbf40539763b1280261 (patch)
tree1ea1ace3ebf47ceb9948892dda79fa37d3e3d425 /src/corelib/io
parent94b136f320b7b84645cc59c89bea52e080fe3a2e (diff)
Revert "QUrl::resolved: keep treating file:name.txt as relative for now"
This reverts commit 91a2c8630b2204831566ab8e523c747f9d8ec927. We promised in the Qt 5.6.2 changelog to do it in Qt 5.8. It was a temporary compatibility hack. [ChangeLog][QtCore][QUrl] The temporary compatibility in QUrl::resolved() that treated the base URL as relative if its scheme matched the current URL's scheme has been removed. Change-Id: I3e4e5051937c40319d6efffd1490eb9a5a948481 Reviewed-by: David Faure <david.faure@kdab.com> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'src/corelib/io')
-rw-r--r--src/corelib/io/qurl.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/corelib/io/qurl.cpp b/src/corelib/io/qurl.cpp
index 066052ade9..c224b032aa 100644
--- a/src/corelib/io/qurl.cpp
+++ b/src/corelib/io/qurl.cpp
@@ -3182,8 +3182,7 @@ QUrl QUrl::resolved(const QUrl &relative) const
if (!relative.d) return *this;
QUrl t;
- // Compatibility hack (mostly for qtdeclarative) : treat "file:relative.txt" as relative even though QUrl::isRelative() says false
- if (!relative.d->scheme.isEmpty() && (!relative.isLocalFile() || QDir::isAbsolutePath(relative.d->path))) {
+ if (!relative.d->scheme.isEmpty()) {
t = relative;
t.detach();
} else {