Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(139)

Side by Side Diff: content/browser/appcache/appcache_update_job.cc

Issue 1131073002: Change content/browser GURL::SchemeIsSecure calls to SchemeIsCryptographic. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | content/browser/loader/resource_dispatcher_host_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/appcache/appcache_update_job.h" 5 #include "content/browser/appcache/appcache_update_job.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/bind_helpers.h" 8 #include "base/bind_helpers.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/strings/string_util.h" 10 #include "base/strings/string_util.h"
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after
162 162
163 if ((response_code / 100) != 2) { 163 if ((response_code / 100) != 2) {
164 if (response_code > 0) 164 if (response_code > 0)
165 result_ = SERVER_ERROR; 165 result_ = SERVER_ERROR;
166 else 166 else
167 result_ = NETWORK_ERROR; 167 result_ = NETWORK_ERROR;
168 OnResponseCompleted(); 168 OnResponseCompleted();
169 return; 169 return;
170 } 170 }
171 171
172 if (url_.SchemeIsSecure()) { 172 if (url_.SchemeIsCryptographic()) {
173 // Do not cache content with cert errors. 173 // Do not cache content with cert errors.
174 // Also, we willfully violate the HTML5 spec at this point in order 174 // Also, we willfully violate the HTML5 spec at this point in order
175 // to support the appcaching of cross-origin HTTPS resources. 175 // to support the appcaching of cross-origin HTTPS resources.
176 // We've opted for a milder constraint and allow caching unless 176 // We've opted for a milder constraint and allow caching unless
177 // the resource has a "no-store" header. A spec change has been 177 // the resource has a "no-store" header. A spec change has been
178 // requested on the whatwg list. 178 // requested on the whatwg list.
179 // See http://code.google.com/p/chromium/issues/detail?id=69594 179 // See http://code.google.com/p/chromium/issues/detail?id=69594
180 // TODO(michaeln): Consider doing this for cross-origin HTTP too. 180 // TODO(michaeln): Consider doing this for cross-origin HTTP too.
181 const net::HttpNetworkSession::Params* session_params = 181 const net::HttpNetworkSession::Params* session_params =
182 request->context()->GetNetworkSessionParams(); 182 request->context()->GetNetworkSessionParams();
(...skipping 1432 matching lines...) Expand 10 before | Expand all | Expand 10 after
1615 1615
1616 // Break the connection with the group so the group cannot call delete 1616 // Break the connection with the group so the group cannot call delete
1617 // on this object after we've posted a task to delete ourselves. 1617 // on this object after we've posted a task to delete ourselves.
1618 group_->SetUpdateAppCacheStatus(AppCacheGroup::IDLE); 1618 group_->SetUpdateAppCacheStatus(AppCacheGroup::IDLE);
1619 group_ = NULL; 1619 group_ = NULL;
1620 1620
1621 base::MessageLoop::current()->DeleteSoon(FROM_HERE, this); 1621 base::MessageLoop::current()->DeleteSoon(FROM_HERE, this);
1622 } 1622 }
1623 1623
1624 } // namespace content 1624 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/browser/loader/resource_dispatcher_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698