| Index: Source/core/fetch/ResourceFetcher.cpp
|
| diff --git a/Source/core/fetch/ResourceFetcher.cpp b/Source/core/fetch/ResourceFetcher.cpp
|
| index ea3ab1fb0d32814a6add28a02b237f4c90700101..16313d0bdac281cfdf92ea711bc31ee79d887a58 100644
|
| --- a/Source/core/fetch/ResourceFetcher.cpp
|
| +++ b/Source/core/fetch/ResourceFetcher.cpp
|
| @@ -894,10 +894,6 @@
|
|
|
| // If the same URL has been loaded as a different type, we need to reload.
|
| if (existingResource->type() != type) {
|
| - // FIXME: If existingResource is a Preload and the new type is LinkPrefetch
|
| - // We really should discard the new prefetch since the preload has more
|
| - // specific type information! crbug.com/379893
|
| - // fast/dom/HTMLLinkElement/link-and-subresource-test hits this case.
|
| WTF_LOG(ResourceLoading, "ResourceFetcher::determineRevalidationPolicy reloading due to type mismatch.");
|
| return Reload;
|
| }
|
| @@ -933,10 +929,6 @@
|
| if (m_allowStaleResources)
|
| return Use;
|
|
|
| - // If fetching a resource with a different 'CORS enabled' flag, reload.
|
| - if (type != Resource::MainResource && options.corsEnabled != existingResource->options().corsEnabled)
|
| - return Reload;
|
| -
|
| // Always use preloads.
|
| if (existingResource->isPreloaded())
|
| return Use;
|
| @@ -951,6 +943,10 @@
|
| WTF_LOG(ResourceLoading, "ResourceFetcher::determineRevalidationPolicy reloading due to Cache-control: no-store.");
|
| return Reload;
|
| }
|
| +
|
| + // If fetching a resource with a different 'CORS enabled' flag, reload.
|
| + if (type != Resource::MainResource && options.corsEnabled != existingResource->options().corsEnabled)
|
| + return Reload;
|
|
|
| // If credentials were sent with the previous request and won't be
|
| // with this one, or vice versa, re-fetch the resource.
|
|
|