summaryrefslogtreecommitdiffstats
path: root/src/corelib/io
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@intel.com>2012-09-20 16:30:48 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2012-10-02 22:34:42 +0200
commit4f52a9509995b1f5c834354ff6d02fa9b4f4396d (patch)
treeb01d4ced4273f7a9f64e88b93e5f6847196cefa7 /src/corelib/io
parent7b696e4ec72bff9a606658e70258fcdba55c6cd0 (diff)
Update some error messages in QUrl::errorString()
Make both invalid hostname messages start with "Invalid hostname". And split the empty port error from the invalid port one. Change-Id: I870d1ed6fb07ec494f553871a37ed167141ffc06 Reviewed-by: David Faure <faure@kde.org> Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
Diffstat (limited to 'src/corelib/io')
-rw-r--r--src/corelib/io/qurl.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/corelib/io/qurl.cpp b/src/corelib/io/qurl.cpp
index b7339a202e..92f613d4c3 100644
--- a/src/corelib/io/qurl.cpp
+++ b/src/corelib/io/qurl.cpp
@@ -3545,7 +3545,7 @@ static QString errorMessage(QUrlPrivate::ErrorCode errorCode, QChar c)
return QString(QStringLiteral("Invalid hostname (character '%1' not permitted)"))
.arg(c);
else
- return QStringLiteral("Hostname contains invalid characters");
+ return QStringLiteral("Invalid hostname (contains invalid characters)");
case QUrlPrivate::InvalidIPv4AddressError:
return QString(); // doesn't happen yet
case QUrlPrivate::InvalidIPv6AddressError:
@@ -3556,8 +3556,9 @@ static QString errorMessage(QUrlPrivate::ErrorCode errorCode, QChar c)
return QStringLiteral("Expected ']' to match '[' in hostname");
case QUrlPrivate::InvalidPortError:
- case QUrlPrivate::PortEmptyError:
return QStringLiteral("Invalid port or port number out of range");
+ case QUrlPrivate::PortEmptyError:
+ return QStringLiteral("Port field was empty");
case QUrlPrivate::InvalidPathError:
return QString(QStringLiteral("Invalid path (character '%1' not permitted)"))