Chromium Code Reviews| Index: third_party/WebKit/Source/platform/loader/fetch/ResourceResponse.cpp |
| diff --git a/third_party/WebKit/Source/platform/loader/fetch/ResourceResponse.cpp b/third_party/WebKit/Source/platform/loader/fetch/ResourceResponse.cpp |
| index ff94534708aa30acb2cff7c44414da04d991bea6..1deef87650236643f0931af34966b9ae691074cb 100644 |
| --- a/third_party/WebKit/Source/platform/loader/fetch/ResourceResponse.cpp |
| +++ b/third_party/WebKit/Source/platform/loader/fetch/ResourceResponse.cpp |
| @@ -101,6 +101,8 @@ ResourceResponse::ResourceResponse() |
| last_modified_(0.0), |
| app_cache_id_(0), |
| response_time_(0), |
| + connection_info_( |
| + net::HttpResponseInfo::ConnectionInfo::CONNECTION_INFO_UNKNOWN), |
| encoded_data_length_(0), |
| encoded_body_length_(0), |
| decoded_body_length_(0) {} |
| @@ -572,6 +574,13 @@ KURL ResourceResponse::OriginalURLViaServiceWorker() const { |
| return url_list_via_service_worker_.back(); |
| } |
| +String ResourceResponse::ConnectionInfoString() const { |
| + std::string connection_info_string = |
| + net::HttpResponseInfo::ConnectionInfoToString(connection_info_); |
| + return String::FromUTF8(connection_info_string.c_str(), |
|
haraken
2017/06/23 03:58:04
Can we use AtomicString(connection_info_string.dat
shaseley
2017/06/23 16:39:22
I see, to avoid the conversion from String to Atom
|
| + connection_info_string.size()); |
| +} |
| + |
| void ResourceResponse::SetEncodedDataLength(long long value) { |
| encoded_data_length_ = value; |
| } |