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

Unified Diff: content/common/socket_stream_dispatcher.cc

Issue 9677031: Bind RenderViewImpl routing_id to SocketStreamHost (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: add CONTENT_EXPORT to ForHandle() Created 8 years, 9 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
« no previous file with comments | « content/browser/renderer_host/socket_stream_host.cc ('k') | content/common/socket_stream_handle_data.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/socket_stream_dispatcher.cc
diff --git a/content/common/socket_stream_dispatcher.cc b/content/common/socket_stream_dispatcher.cc
index 640a15b83dba608df5bc434012bfbf45a72cb1a6..f573329d5d92ae9dfab6c197c57bc731b6bc9ab4 100644
--- a/content/common/socket_stream_dispatcher.cc
+++ b/content/common/socket_stream_dispatcher.cc
@@ -13,6 +13,7 @@
#include "base/message_loop.h"
#include "content/common/child_thread.h"
#include "content/common/socket_stream.h"
+#include "content/common/socket_stream_handle_data.h"
#include "content/common/socket_stream_messages.h"
#include "googleurl/src/gurl.h"
#include "webkit/glue/websocketstreamhandle_bridge.h"
@@ -146,8 +147,14 @@ void IPCWebSocketStreamHandleBridge::DoConnect(const GURL& url) {
socket_id_ = all_bridges.Get().Add(this);
DCHECK_NE(socket_id_, content::kNoSocketId);
+ int render_view_id = MSG_ROUTING_NONE;
+ const SocketStreamHandleData* data =
+ SocketStreamHandleData::ForHandle(handle_);
+ if (data)
+ render_view_id = data->render_view_id();
AddRef(); // Released in OnClosed().
- if (child_thread_->Send(new SocketStreamHostMsg_Connect(url, socket_id_))) {
+ if (child_thread_->Send(
+ new SocketStreamHostMsg_Connect(render_view_id, url, socket_id_))) {
DVLOG(1) << "Connect socket_id=" << socket_id_;
// TODO(ukai): timeout to OnConnected.
} else {
« no previous file with comments | « content/browser/renderer_host/socket_stream_host.cc ('k') | content/common/socket_stream_handle_data.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698