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

Side by Side Diff: content/browser/renderer_host/cross_site_resource_handler.cc

Issue 10599002: Fix HTML5 video streaming. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 6 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 | Annotate | Revision Log
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 <string> 5 #include <string>
6 6
7 #include "content/browser/renderer_host/cross_site_resource_handler.h" 7 #include "content/browser/renderer_host/cross_site_resource_handler.h"
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
45 has_started_response_(false), 45 has_started_response_(false),
46 in_cross_site_transition_(false), 46 in_cross_site_transition_(false),
47 request_id_(-1), 47 request_id_(-1),
48 completed_during_transition_(false), 48 completed_during_transition_(false),
49 did_defer_(false), 49 did_defer_(false),
50 completed_status_(), 50 completed_status_(),
51 response_(NULL) { 51 response_(NULL) {
52 } 52 }
53 53
54 CrossSiteResourceHandler::~CrossSiteResourceHandler() { 54 CrossSiteResourceHandler::~CrossSiteResourceHandler() {
55 // Cleanup back-pointer stored on the request info.
56 ResourceRequestInfoImpl::ForRequest(request_)->set_cross_site_handler(NULL);
55 } 57 }
56 58
57 bool CrossSiteResourceHandler::OnRequestRedirected( 59 bool CrossSiteResourceHandler::OnRequestRedirected(
58 int request_id, 60 int request_id,
59 const GURL& new_url, 61 const GURL& new_url,
60 ResourceResponse* response, 62 ResourceResponse* response,
61 bool* defer) { 63 bool* defer) {
62 // We should not have started the transition before being redirected. 64 // We should not have started the transition before being redirected.
63 DCHECK(!in_cross_site_transition_); 65 DCHECK(!in_cross_site_transition_);
64 return next_handler_->OnRequestRedirected( 66 return next_handler_->OnRequestRedirected(
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after
218 } 220 }
219 221
220 void CrossSiteResourceHandler::ResumeIfDeferred() { 222 void CrossSiteResourceHandler::ResumeIfDeferred() {
221 if (did_defer_) { 223 if (did_defer_) {
222 did_defer_ = false; 224 did_defer_ = false;
223 controller()->Resume(); 225 controller()->Resume();
224 } 226 }
225 } 227 }
226 228
227 } // namespace content 229 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698