Ignore:
Timestamp:
May 5, 2011, 5:36:53 AM (15 years ago)
Author:
Dmitry A. Kuminov
Message:

trunk: Merged in qt 4.7.2 sources from branches/vendor/nokia/qt.

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk

  • trunk/src/network/access/qnetworkrequest.cpp

    r769 r846  
    11/****************************************************************************
    22**
    3 ** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
     3** Copyright (C) 201 Nokia Corporation and/or its subsidiary(-ies).
    44** All rights reserved.
    55** Contact: Nokia Corporation ([email protected])
     
    106106/*!
    107107    \enum QNetworkRequest::Attribute
    108 
     108    \since 4.7
     109   
    109110    Attribute codes for the QNetworkRequest and QNetworkReply.
    110111
     
    175176        header must be set.
    176177
    177      \value HttpPipeliningAllowedAttribute
     178    \value HttpPipeliningAllowedAttribute
    178179        Requests only, type: QVariant::Bool (default: false)
    179180        Indicates whether the QNetworkAccessManager code is
    180181        allowed to use HTTP pipelining with this request.
    181182
    182      \value HttpPipeliningWasUsedAttribute
     183    \value HttpPipeliningWasUsedAttribute
    183184        Replies only, type: QVariant::Bool
    184185        Indicates whether the HTTP pipelining was used for receiving
    185186        this reply.
     187
     188
     189
     190
     191
     192
     193
     194
     195
     196
     197
     198
     199
     200
     201
     202
     203
     204
     205
     206
     207
     208
     209
     210
     211
     212
     213
     214
     215
     216
     217
     218
     219
     220
     221
     222
     223
     224
     225
     226
     227
    186228
    187229    \value User
     
    217259*/
    218260
     261
     262
     263
     264
     265
     266
     267
     268
     269
     270
     271
     272
    219273class QNetworkRequestPrivate: public QSharedData, public QNetworkHeadersPrivate
    220274{
    221275public:
    222276    inline QNetworkRequestPrivate()
     277
    223278#ifndef QT_NO_OPENSSL
    224         : sslConfiguration(0)
     279        sslConfiguration(0)
    225280#endif
    226281    { qRegisterMetaType<QNetworkRequest>(); }
     
    237292    {
    238293        url = other.url;
     294
    239295
    240296#ifndef QT_NO_OPENSSL
     
    248304    {
    249305        return url == other.url &&
     306
    250307            rawHeaders == other.rawHeaders &&
    251308            attributes == other.attributes;
     
    254311
    255312    QUrl url;
     313
    256314#ifndef QT_NO_OPENSSL
    257315    mutable QSslConfiguration *sslConfiguration;
     
    517575{
    518576    return d->originatingObject.data();
     577
     578
     579
     580
     581
     582
     583
     584
     585
     586
     587
     588
     589
     590
     591
     592
     593
     594
     595
     596
     597
     598
     599
     600
     601
     602
     603
     604
     605
     606
     607
     608
     609
     610
     611
     612
     613
     614
     615
    519616}
    520617
     
    803900    QNetworkRequest::KnownHeaders parsedKey = parseHeaderName(key);
    804901    if (parsedKey != QNetworkRequest::KnownHeaders(-1)) {
    805         if (value.isNull())
     902        if (value.isNull())
    806903            cookedHeaders.remove(parsedKey);
    807         else
     904        } else if (parsedKey == QNetworkRequest::ContentLengthHeader
     905                 && cookedHeaders.contains(QNetworkRequest::ContentLengthHeader)) {
     906            // Only set the cooked header "Content-Length" once.
     907            // See bug QTBUG-15311
     908        } else {
    808909            cookedHeaders.insert(parsedKey, parseHeaderValue(parsedKey, value));
     910
     911
    809912    }
    810913}
Note: See TracChangeset for help on using the changeset viewer.