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

Side by Side Diff: chrome/renderer/webworker_proxy.h

Issue 266036: Fix another race condition on worker process shutdown that results in use-aft... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 2 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
« no previous file with comments | « no previous file | chrome/renderer/webworker_proxy.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 #ifndef CHROME_RENDERER_WEBWORKER_PROXY_H_ 5 #ifndef CHROME_RENDERER_WEBWORKER_PROXY_H_
6 #define CHROME_RENDERER_WEBWORKER_PROXY_H_ 6 #define CHROME_RENDERER_WEBWORKER_PROXY_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 20 matching lines...) Expand all
31 31
32 // WebWorker implementation. 32 // WebWorker implementation.
33 virtual void startWorkerContext(const WebKit::WebURL& script_url, 33 virtual void startWorkerContext(const WebKit::WebURL& script_url,
34 const WebKit::WebString& user_agent, 34 const WebKit::WebString& user_agent,
35 const WebKit::WebString& source_code); 35 const WebKit::WebString& source_code);
36 virtual void terminateWorkerContext(); 36 virtual void terminateWorkerContext();
37 virtual void postMessageToWorkerContext( 37 virtual void postMessageToWorkerContext(
38 const WebKit::WebString& message, 38 const WebKit::WebString& message,
39 const WebKit::WebMessagePortChannelArray& channel_array); 39 const WebKit::WebMessagePortChannelArray& channel_array);
40 virtual void workerObjectDestroyed(); 40 virtual void workerObjectDestroyed();
41 virtual void clientDestroyed();
41 42
42 // IPC::Channel::Listener implementation. 43 // IPC::Channel::Listener implementation.
43 void OnMessageReceived(const IPC::Message& message); 44 void OnMessageReceived(const IPC::Message& message);
44 45
45 private: 46 private:
46 bool Send(IPC::Message* message); 47 bool Send(IPC::Message* message);
47 48
48 void OnDedicatedWorkerCreated(); 49 void OnDedicatedWorkerCreated();
49 void OnPostMessage(const string16& message, 50 void OnPostMessage(const string16& message,
50 const std::vector<int>& sent_message_port_ids, 51 const std::vector<int>& sent_message_port_ids,
(...skipping 15 matching lines...) Expand all
66 // messages. 67 // messages.
67 WebKit::WebWorkerClient* client_; 68 WebKit::WebWorkerClient* client_;
68 69
69 // Stores messages that were sent before the StartWorkerContext message. 70 // Stores messages that were sent before the StartWorkerContext message.
70 std::vector<IPC::Message*> queued_messages_; 71 std::vector<IPC::Message*> queued_messages_;
71 72
72 DISALLOW_COPY_AND_ASSIGN(WebWorkerProxy); 73 DISALLOW_COPY_AND_ASSIGN(WebWorkerProxy);
73 }; 74 };
74 75
75 #endif // CHROME_RENDERER_WEBWORKER_PROXY_H_ 76 #endif // CHROME_RENDERER_WEBWORKER_PROXY_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/renderer/webworker_proxy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698