Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 #include "core/fetch/ResourceLoaderOptions.h" | |
| 5 | |
| 6 namespace blink { | |
| 7 | |
| 8 bool ResourceLoaderOptions::canReuseRequest(const ResourceLoaderOptions& other) const | |
|
Nate Chapin
2016/03/17 22:58:18
Why create a .cpp for this?
Yoav Weiss
2016/03/18 07:53:14
Because a ~2000 file rebuild every time I experime
| |
| 9 { | |
| 10 // dataBufferingPolicy differences are believed to be safe for re-use. | |
| 11 // FIXME: check allowCredentials. | |
| 12 // FIXME: check credentialsRequested. | |
| 13 // FIXME: check contentSecurityPolicyOption. | |
| 14 // initiatorInfo is purely informational and should be benign for re-use. | |
| 15 // requestInitiatorContext is benign (indicates document vs. worker) | |
| 16 // synchronousPolicy (safe to re-use an async XHR response for sync, etc.) | |
| 17 return corsEnabled == other.corsEnabled || (sameOrigin == other.sameOrigin & & sameOrigin == IsSameOrigin); | |
| 18 // securityOrigin has more complicated checks which callers are responsible for. | |
| 19 } | |
| 20 | |
| 21 } | |
| OLD | NEW |