diff options
author | Thiago Macieira <thiago.macieira@intel.com> | 2013-07-02 13:32:38 -0700 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-07-20 05:07:02 +0200 |
commit | 6130bb22e754eec132e49e5f254bcedc935e69b0 (patch) | |
tree | 587f33f3e6c1ebdb006431e1a7dff7b03a23661e /src/corelib/io/qurl.cpp | |
parent | 3d77406e27230089e5a847b03c93d66117343d75 (diff) |
QUrl: Uppercase the version number in IPvFuture
We don't know what it might be used for. The RFC for URI says it's an
HEXDIG, and since we uppercase all other HEXDIGs already (in
percent-encodings...).
Change-Id: I56d0a81315576dd98eaa2657c0307d79332543a5
Reviewed-by: David Faure (KDE) <faure@kde.org>
Diffstat (limited to 'src/corelib/io/qurl.cpp')
-rw-r--r-- | src/corelib/io/qurl.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/corelib/io/qurl.cpp b/src/corelib/io/qurl.cpp index be4f177515..3c8483029a 100644 --- a/src/corelib/io/qurl.cpp +++ b/src/corelib/io/qurl.cpp @@ -1105,6 +1105,10 @@ static const QChar *parseIpFuture(QString &host, const QChar *begin, const QChar // decode the whole string, skipping the "[vH." and "]" which we already know to be there host += QString::fromRawData(begin, 4); + // uppercase the version, if necessary + if (begin[2].unicode() >= 'a') + host[host.length() - 2] = begin[2].unicode() - 0x20; + begin += 4; --end; |