| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011, 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2011, 2012 Google Inc. All rights reserved. |
| 3 * Copyright (C) 2013, Intel Corporation | 3 * Copyright (C) 2013, Intel Corporation |
| 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 are | 6 * modification, are permitted provided that the following conditions are |
| 7 * met: | 7 * met: |
| 8 * | 8 * |
| 9 * * Redistributions of source code must retain the above copyright | 9 * * 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 800 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 811 if (resource() && resource()->loader()) { | 811 if (resource() && resource()->loader()) { |
| 812 unsigned long identifier = resource()->identifier(); | 812 unsigned long identifier = resource()->identifier(); |
| 813 InspectorInstrumentation::documentThreadableLoaderStartedLoadingForC
lient(m_document, identifier, m_client); | 813 InspectorInstrumentation::documentThreadableLoaderStartedLoadingForC
lient(m_document, identifier, m_client); |
| 814 } | 814 } |
| 815 return; | 815 return; |
| 816 } | 816 } |
| 817 | 817 |
| 818 FetchRequest fetchRequest(request, m_options.initiator, resourceLoaderOption
s); | 818 FetchRequest fetchRequest(request, m_options.initiator, resourceLoaderOption
s); |
| 819 if (m_options.crossOriginRequestPolicy == AllowCrossOriginRequests) | 819 if (m_options.crossOriginRequestPolicy == AllowCrossOriginRequests) |
| 820 fetchRequest.setOriginRestriction(FetchRequest::NoOriginRestriction); | 820 fetchRequest.setOriginRestriction(FetchRequest::NoOriginRestriction); |
| 821 ResourcePtr<Resource> resource = RawResource::fetchSynchronously(fetchReques
t, document().fetcher()); | 821 RefPtrWillBeRawPtr<Resource> resource = RawResource::fetchSynchronously(fetc
hRequest, document().fetcher()); |
| 822 ResourceResponse response = resource ? resource->response() : ResourceRespon
se(); | 822 ResourceResponse response = resource ? resource->response() : ResourceRespon
se(); |
| 823 unsigned long identifier = resource ? resource->identifier() : std::numeric_
limits<unsigned long>::max(); | 823 unsigned long identifier = resource ? resource->identifier() : std::numeric_
limits<unsigned long>::max(); |
| 824 ResourceError error = resource ? resource->resourceError() : ResourceError()
; | 824 ResourceError error = resource ? resource->resourceError() : ResourceError()
; |
| 825 | 825 |
| 826 InspectorInstrumentation::documentThreadableLoaderStartedLoadingForClient(m_
document, identifier, m_client); | 826 InspectorInstrumentation::documentThreadableLoaderStartedLoadingForClient(m_
document, identifier, m_client); |
| 827 | 827 |
| 828 if (!resource) { | 828 if (!resource) { |
| 829 m_client->didFail(error); | 829 m_client->didFail(error); |
| 830 return; | 830 return; |
| 831 } | 831 } |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 894 return m_securityOrigin ? m_securityOrigin.get() : document().securityOrigin
(); | 894 return m_securityOrigin ? m_securityOrigin.get() : document().securityOrigin
(); |
| 895 } | 895 } |
| 896 | 896 |
| 897 Document& DocumentThreadableLoader::document() const | 897 Document& DocumentThreadableLoader::document() const |
| 898 { | 898 { |
| 899 ASSERT(m_document); | 899 ASSERT(m_document); |
| 900 return *m_document; | 900 return *m_document; |
| 901 } | 901 } |
| 902 | 902 |
| 903 } // namespace blink | 903 } // namespace blink |
| OLD | NEW |