summaryrefslogtreecommitdiffstats
path: root/webkit/glue
diff options
context:
space:
mode:
authorvsevik@chromium.org <vsevik@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-04-06 12:16:21 +0000
committervsevik@chromium.org <vsevik@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-04-06 12:16:21 +0000
commite2fefe23d79a1de960d8903d9bb8520e6d1e1bd6 (patch)
treec19f4884e8e31288913faa369eec327412709543 /webkit/glue
parent8ec3fbec285daa194f6397b998b4c4bc0c1b2a37 (diff)
downloadchromium_src-e2fefe23d79a1de960d8903d9bb8520e6d1e1bd6.zip
chromium_src-e2fefe23d79a1de960d8903d9bb8520e6d1e1bd6.tar.gz
chromium_src-e2fefe23d79a1de960d8903d9bb8520e6d1e1bd6.tar.bz2
Fixed network data for data url resources
BUG=69810 TEST=Open DevTools, open site having data url resource, observe small time/latency values (e.g. 2ms). Review URL: http://codereview.chromium.org/6693095 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80607 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/glue')
-rw-r--r--webkit/glue/weburlloader_impl.cc32
1 files changed, 17 insertions, 15 deletions
diff --git a/webkit/glue/weburlloader_impl.cc b/webkit/glue/weburlloader_impl.cc
index 6182815..e09c95b 100644
--- a/webkit/glue/weburlloader_impl.cc
+++ b/webkit/glue/weburlloader_impl.cc
@@ -194,22 +194,24 @@ void PopulateURLResponse(
response->setConnectionReused(info.connection_reused);
response->setDownloadFilePath(FilePathToWebString(info.download_file_path));
- WebURLLoadTiming timing;
- timing.initialize();
const ResourceLoadTimingInfo& timing_info = info.load_timing;
- timing.setRequestTime(timing_info.base_time.ToDoubleT());
- timing.setProxyStart(timing_info.proxy_start);
- timing.setProxyEnd(timing_info.proxy_end);
- timing.setDNSStart(timing_info.dns_start);
- timing.setDNSEnd(timing_info.dns_end);
- timing.setConnectStart(timing_info.connect_start);
- timing.setConnectEnd(timing_info.connect_end);
- timing.setSSLStart(timing_info.ssl_start);
- timing.setSSLEnd(timing_info.ssl_end);
- timing.setSendStart(timing_info.send_start);
- timing.setSendEnd(timing_info.send_end);
- timing.setReceiveHeadersEnd(timing_info.receive_headers_end);
- response->setLoadTiming(timing);
+ if (!timing_info.base_time.is_null()) {
+ WebURLLoadTiming timing;
+ timing.initialize();
+ timing.setRequestTime(timing_info.base_time.ToDoubleT());
+ timing.setProxyStart(timing_info.proxy_start);
+ timing.setProxyEnd(timing_info.proxy_end);
+ timing.setDNSStart(timing_info.dns_start);
+ timing.setDNSEnd(timing_info.dns_end);
+ timing.setConnectStart(timing_info.connect_start);
+ timing.setConnectEnd(timing_info.connect_end);
+ timing.setSSLStart(timing_info.ssl_start);
+ timing.setSSLEnd(timing_info.ssl_end);
+ timing.setSendStart(timing_info.send_start);
+ timing.setSendEnd(timing_info.send_end);
+ timing.setReceiveHeadersEnd(timing_info.receive_headers_end);
+ response->setLoadTiming(timing);
+ }
if (info.devtools_info.get()) {
WebHTTPLoadInfo load_info;