Work around a bug in Qt's QHttp implementation and
authorlars <lars@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 14 Jun 2007 03:28:36 +0000 (03:28 +0000)
committerlars <lars@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 14 Jun 2007 03:28:36 +0000 (03:28 +0000)
        get web pages to load again.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@23519 268f45cc-cd09-0410-ab3c-d52691b4dbfc

WebKitQt/Api/qwebpage.cpp
WebKitQt/ChangeLog

index cd741866fe43148d5c187a904185c442fea207b4..00ac10ce10da0c1f3af218e115481c8b653ac214 100644 (file)
@@ -148,8 +148,11 @@ void QWebPage::open(const QWebNetworkRequest &req)
     if (!method.isEmpty())
         request.setHTTPMethod(method);
 
-    foreach (QString key, httpHeader.keys())
-        request.addHTTPHeaderField(key, httpHeader.value(key));
+    QList<QPair<QString, QString> > values = httpHeader.values();
+    for (int i = 0; i < values.size(); ++i) {
+        const QPair<QString, QString> &val = values.at(i);
+        request.addHTTPHeaderField(val.first, val.second);
+    }
 
     if (!postData.isEmpty()) {
         WTF::RefPtr<WebCore::FormData> formData = new WebCore::FormData(postData.constData(), postData.size());
index f5913518198272a979609a5d5140dfc4f06fed1a..6481797a030758cc6c53f6684f0bf08713f4a6e1 100644 (file)
@@ -1,3 +1,13 @@
+2007-06-14  Lars Knoll <lars@trolltech.com>
+
+        Reviewed by George.
+
+        Work around a bug in Qt's QHttp implementation and
+        get web pages to load again.
+
+        * Api/qwebpage.cpp:
+        (QWebPage::open):
+
 2007-06-13  Simon Hausmann  <hausmann@kde.org>
 
         Reviewed by Lars.