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

Unified Diff: content/renderer/websharedworker_proxy.h

Issue 2607753002: SharedWorker: Make sure route_id is always valid in WebSharedWorkerProxy (Closed)
Patch Set: Created 4 years 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 | « no previous file | content/renderer/websharedworker_proxy.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/websharedworker_proxy.h
diff --git a/content/renderer/websharedworker_proxy.h b/content/renderer/websharedworker_proxy.h
index a1c74a3faf2ac3bb7cee0c2c7de67d4f30947749..9c854469bf3910ccd0888c7a06916e56e3bf6631 100644
--- a/content/renderer/websharedworker_proxy.h
+++ b/content/renderer/websharedworker_proxy.h
@@ -28,7 +28,6 @@ namespace content {
class WebSharedWorkerProxy : public blink::WebSharedWorkerConnector,
private IPC::Listener {
public:
- // If the worker not loaded yet, route_id == MSG_ROUTING_NONE
WebSharedWorkerProxy(IPC::MessageRouter* router, int route_id);
~WebSharedWorkerProxy() override;
@@ -40,9 +39,6 @@ class WebSharedWorkerProxy : public blink::WebSharedWorkerConnector,
// IPC::Listener implementation.
bool OnMessageReceived(const IPC::Message& message) override;
- // Disconnects the worker (stops listening for incoming messages).
- void Disconnect();
-
// Sends a message to the worker thread (forwarded via the RenderViewHost).
// If WorkerStarted() has not yet been called, message is queued.
bool Send(std::unique_ptr<IPC::Message> message);
@@ -58,7 +54,7 @@ class WebSharedWorkerProxy : public blink::WebSharedWorkerConnector,
// worker, and also to route messages to the worker (WorkerService contains
// a map that maps between these renderer-side route IDs and worker-side
// routing ids).
- int route_id_;
+ const int route_id_;
IPC::MessageRouter* const router_;
« no previous file with comments | « no previous file | content/renderer/websharedworker_proxy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698