|
OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2014 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 | |
5 #ifndef CONTENT_BROWSER_RENDERER_HOST_CROSS_SITE_REQUEST_TRANSFER_H_ | |
6 #define CONTENT_BROWSER_RENDERER_HOST_CROSS_SITE_REQUEST_TRANSFER_H_ | |
Charlie Reis
2014/02/13 22:12:19
I think this would belong in frame_host rather tha
mmenke
2014/02/14 16:30:02
I tried to have it in frame_host. Unfortunately,
mmenke
2014/02/14 17:10:20
"Pass it around" == Pass the request ID around wit
Charlie Reis
2014/02/15 01:25:44
Oh, RVH needs it for now. Ok, you can leave it he
| |
7 | |
8 #include "base/basictypes.h" | |
9 #include "content/common/content_export.h" | |
10 | |
11 namespace content { | |
12 | |
13 class CrossSiteResourceHandler; | |
14 | |
15 // A UI thread object that owns a request being transferred. Deleting the | |
16 // object without releasing the request will delete the underlying URLRequest. | |
17 // This is needed to clean up the URLRequest when a cross site navigation is | |
18 // cancelled. | |
19 class CONTENT_EXPORT CrossSiteRequestTransfer { | |
Charlie Reis
2014/02/13 22:12:19
CrossSiteRequest or CrossSiteTransferringRequest,
mmenke
2014/02/14 16:30:02
I considered "CrossSiteRequest", but I didn't like
| |
20 public: | |
21 explicit CrossSiteRequestTransfer( | |
22 CrossSiteResourceHandler* cross_site_resource_handler); | |
23 ~CrossSiteRequestTransfer(); | |
24 | |
25 // Relinquishes ownership of the request, so another process can take | |
26 // control of it. | |
27 void ReleaseRequest(); | |
28 | |
29 private: | |
30 // No need for a weak pointer here - nothing should have ownership of the | |
31 // cross site request until after |this| is deleted, or ReleaseRequest is | |
32 // called. | |
33 CrossSiteResourceHandler* cross_site_resource_handler_; | |
Charlie Reis
2014/02/13 22:12:19
I'm not yet convinced this is safe, because CrossS
mmenke
2014/02/14 16:30:02
If it can be, then we don't actually own it, and t
| |
34 | |
35 DISALLOW_COPY_AND_ASSIGN(CrossSiteRequestTransfer); | |
36 }; | |
37 | |
38 } // namespace content | |
39 | |
40 #endif // CONTENT_BROWSER_RENDERER_HOST_CROSS_SITE_REQUEST_TRANSFER_H_ | |
OLD | NEW |