OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) 2006, 2007, 2010, 2011 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006, 2007, 2010, 2011 Apple Inc. All rights reserved. |
3 * (C) 2007 Graham Dennis (graham.dennis@gmail.com) | 3 * (C) 2007 Graham Dennis (graham.dennis@gmail.com) |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
8 * | 8 * |
9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 498 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
509 } | 509 } |
510 didFail(0, errorOut); | 510 didFail(0, errorOut); |
511 return; | 511 return; |
512 } | 512 } |
513 didReceiveResponse(0, responseOut); | 513 didReceiveResponse(0, responseOut); |
514 if (m_state == Terminated) | 514 if (m_state == Terminated) |
515 return; | 515 return; |
516 RefPtr<ResourceLoadInfo> resourceLoadInfo = responseOut.toResourceResponse() .resourceLoadInfo(); | 516 RefPtr<ResourceLoadInfo> resourceLoadInfo = responseOut.toResourceResponse() .resourceLoadInfo(); |
517 int64_t encodedDataLength = resourceLoadInfo ? resourceLoadInfo->encodedData Length : WebURLLoaderClient::kUnknownEncodedDataLength; | 517 int64_t encodedDataLength = resourceLoadInfo ? resourceLoadInfo->encodedData Length : WebURLLoaderClient::kUnknownEncodedDataLength; |
518 m_fetcher->didReceiveData(m_resource, dataOut.data(), dataOut.size(), encode dDataLength); | 518 m_fetcher->didReceiveData(m_resource, dataOut.data(), dataOut.size(), encode dDataLength); |
519 m_resource->setResourceBuffer(dataOut); | 519 if (dataOut.size()) |
Yoav Weiss
2015/12/31 06:29:17
Isn't there a scenario where the response *has* ch
Nate Chapin
2016/01/04 22:15:54
In all non-revalidation cases, Resource::m_data wi
Yoav Weiss
2016/01/05 14:13:03
What's the relationship between Resource::m_data a
| |
520 m_resource->setResourceBuffer(dataOut); | |
520 didFinishLoading(0, monotonicallyIncreasingTime(), encodedDataLength); | 521 didFinishLoading(0, monotonicallyIncreasingTime(), encodedDataLength); |
521 } | 522 } |
522 | 523 |
523 ResourceRequest& ResourceLoader::applyOptions(ResourceRequest& request) const | 524 ResourceRequest& ResourceLoader::applyOptions(ResourceRequest& request) const |
524 { | 525 { |
525 request.setAllowStoredCredentials(m_options.allowCredentials == AllowStoredC redentials); | 526 request.setAllowStoredCredentials(m_options.allowCredentials == AllowStoredC redentials); |
526 return request; | 527 return request; |
527 } | 528 } |
528 | 529 |
529 } | 530 } |
OLD | NEW |