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

Unified Diff: content/browser/websockets/websocket_handshake_request_info_impl.cc

Issue 2815913005: Switch to using scoped_ptr with UserData (Closed)
Patch Set: fixes Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/websockets/websocket_handshake_request_info_impl.cc
diff --git a/content/browser/websockets/websocket_handshake_request_info_impl.cc b/content/browser/websockets/websocket_handshake_request_info_impl.cc
index 14bb5cb184b011dc9b957dacf589722809afb9a3..13b7761fd547c156667b81034429eaa4e0769ec3 100644
--- a/content/browser/websockets/websocket_handshake_request_info_impl.cc
+++ b/content/browser/websockets/websocket_handshake_request_info_impl.cc
@@ -4,6 +4,7 @@
#include "content/browser/websockets/websocket_handshake_request_info_impl.h"
+#include "base/memory/ptr_util.h"
#include "net/url_request/url_request.h"
namespace content {
@@ -25,8 +26,9 @@ void WebSocketHandshakeRequestInfoImpl::CreateInfoAndAssociateWithRequest(
int child_id,
int render_frame_id,
net::URLRequest* request) {
- request->SetUserData(
- &g_tag, new WebSocketHandshakeRequestInfoImpl(child_id, render_frame_id));
+ request->SetUserData(&g_tag,
+ base::WrapUnique(new WebSocketHandshakeRequestInfoImpl(
+ child_id, render_frame_id)));
}
int WebSocketHandshakeRequestInfoImpl::GetChildId() const {

Powered by Google App Engine
This is Rietveld 408576698