qt5base-lts/tests/auto/corelib/io
Thiago Macieira f62768d046 QUrl: re-fix the setPath("//path") case leading to scheme://path
Commits aba336c2b4 (in Qt 5.2) and
aba336c2b4 (in 5.6) both tried to deal
with this problem, with different levels of success. This is the third
attempt (and hopefully the charm).

Instead of modifying the path that the user provides, go straight ahead
and declare it invalid. This is supported by RFC 3986, which declares
this expansion impossible:

   relative-part = "//" authority path-abempty
                 / path-absolute
                 / path-noscheme
                 / path-empty
   path-abempty  = *( "/" segment )
   path-absolute = "/" [ segment-nz *( "/" segment ) ]
   path-noscheme = segment-nz-nc *( "/" segment )

The "path-abempty" and "path-noscheme" cases are the two issues we
already handle. This commit adds the third one: path-absolute, which
requires that the first segment of the path be of non-zero length.

That is, it is now possible again to have http://example.com//path
constructed piece-wise, without it producing http://example.com/path.
Additionally, it catches the case of http://example.com//path parsed
from full URL then followed by setAuthority("").

Change-Id: I69f37f9304f24709a823fffd14e67a5e7212ddcd
Reviewed-by: David Faure <david.faure@kdab.com>
2017-10-06 03:49:40 +00:00
..
largefile Use QSharedPointer::create() more 2017-07-19 13:40:42 +00:00
qabstractfileengine Use QSharedPointer::create() more 2017-07-19 13:40:42 +00:00
qbuffer Updated license headers 2016-01-21 18:55:18 +00:00
qdatastream Use QSharedPointer::create() more 2017-07-19 13:40:42 +00:00
qdataurl Updated license headers 2016-01-21 18:55:18 +00:00
qdebug Merge remote-tracking branch 'origin/5.6' into 5.7 2016-06-10 23:27:10 +02:00
qdir Remove unnecessary VxWorks ifdef 2017-09-18 21:06:25 +00:00
qdiriterator Merge remote-tracking branch 'origin/5.7' into dev 2016-06-13 12:46:46 +02:00
qfile Revert "Make QFile::open fail when using an invalid file name" 2017-07-27 15:42:55 +00:00
qfileinfo Fix resolution of relative links on Windows 2017-09-04 07:35:09 +00:00
qfileselector Merge remote-tracking branch 'origin/5.8' into 5.9 2017-04-18 10:46:22 +02:00
qfilesystementry Updated license headers 2016-01-21 18:55:18 +00:00
qfilesystemmetadata tests: Unify license to GPL-EXCEPT 2017-04-03 07:18:46 +00:00
qfilesystemwatcher QFileSystemWatcher/Windows: Recreate handle for files 2017-07-07 07:02:45 +00:00
qiodevice Use QSharedPointer::create() more 2017-07-19 13:40:42 +00:00
qipaddress Merge remote-tracking branch 'origin/5.6' into 5.7 2016-04-13 06:55:37 +02:00
qlockfile Merge remote-tracking branch 'origin/5.8' into 5.9 2017-03-21 19:07:53 +01:00
qloggingcategory Updated license headers 2016-01-21 18:55:18 +00:00
qloggingregistry QLoggingRegistry: remove rules vector 2017-04-21 07:16:33 +00:00
qnodebug Updated license headers 2016-01-21 18:55:18 +00:00
qprocess tst_QProcess/tst_QFile: Extend blacklisting to MSVC2017 2017-07-05 12:42:14 +00:00
qprocess-noapplication macOS: Don't build auto-tests as application bundles unless explicitly requested 2016-10-23 10:39:56 +00:00
qprocessenvironment QtCore: Remove Windows CE. 2016-03-30 11:22:47 +00:00
qresourceengine unbreak tst_qresourceengine for prefix builds 2017-08-03 04:54:56 +00:00
qsavefile Updated license headers 2016-01-21 18:55:18 +00:00
qsettings Merge remote-tracking branch 'origin/5.8' into 5.9 2017-02-08 15:49:18 +01:00
qstandardpaths Fix tests that assume system files are owned by root for qemu 2017-04-26 09:12:12 +00:00
qstorageinfo Merge remote-tracking branch 'origin/5.7' into dev 2016-05-23 21:09:46 +02:00
qtemporarydir Fix tests that assume system files are owned by root for qemu 2017-04-26 09:12:12 +00:00
qtemporaryfile Autotest: Fix test when running on a non-Unicode-capable locale 2017-08-12 07:56:39 +00:00
qtextstream winrt: Fix tst_qtextstream 2017-06-19 07:06:01 +00:00
qurl QUrl: re-fix the setPath("//path") case leading to scheme://path 2017-10-06 03:49:40 +00:00
qurlinternal QUrl: fix IDN conversion when the ACE form is invalid 2017-04-25 00:51:43 +00:00
qurlquery Updated license headers 2016-01-21 18:55:18 +00:00
qwinoverlappedionotifier Updated license headers 2016-01-21 18:55:18 +00:00
io.pro Merge remote-tracking branch 'origin/5.8' into 5.9 2017-03-27 10:42:08 +02:00