From c3d3604f4c7213d61e44ba0c310c270d08f881dd Mon Sep 17 00:00:00 2001 From: Thiago Macieira Date: Tue, 15 Dec 2015 21:14:29 +0900 Subject: Make QUrl::removeAllQueryItems actually remove the query items We forgot to setQuery() after the query was modified. Task-number: QTBUG-49963 Change-Id: I11f559ef75544c50b3f8ffff1420148ba3092200 Reviewed-by: Oswald Buddenhagen Reviewed-by: David Faure --- src/corelib/io/qurlquery.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/corelib/io') diff --git a/src/corelib/io/qurlquery.h b/src/corelib/io/qurlquery.h index ae3a79c119..8fcc1b13d5 100644 --- a/src/corelib/io/qurlquery.h +++ b/src/corelib/io/qurlquery.h @@ -121,7 +121,7 @@ inline QStringList QUrl::allQueryItemValues(const QString &key) const inline void QUrl::removeQueryItem(const QString &key) { QUrlQuery q(*this); q.removeQueryItem(key); setQuery(q); } inline void QUrl::removeAllQueryItems(const QString &key) -{ QUrlQuery q(*this); q.removeAllQueryItems(key); } +{ QUrlQuery q(*this); q.removeAllQueryItems(key); setQuery(q); } inline void QUrl::addEncodedQueryItem(const QByteArray &key, const QByteArray &value) { QUrlQuery q(*this); q.addQueryItem(fromEncodedComponent_helper(key), fromEncodedComponent_helper(value)); setQuery(q); } @@ -132,7 +132,7 @@ inline QByteArray QUrl::encodedQueryItemValue(const QByteArray &key) const inline void QUrl::removeEncodedQueryItem(const QByteArray &key) { QUrlQuery q(*this); q.removeQueryItem(fromEncodedComponent_helper(key)); setQuery(q); } inline void QUrl::removeAllEncodedQueryItems(const QByteArray &key) -{ QUrlQuery q(*this); q.removeAllQueryItems(fromEncodedComponent_helper(key)); } +{ QUrlQuery q(*this); q.removeAllQueryItems(fromEncodedComponent_helper(key)); setQuery(q); } inline void QUrl::setEncodedQueryItems(const QList > &qry) { -- cgit v1.2.3