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

Unified Diff: ppapi/proxy/dispatcher.h

Issue 6493004: Implement basic crash detection and shutdown handling for out of process PPAP... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 10 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 | « ppapi/ppapi_cpp.gypi ('k') | ppapi/proxy/dispatcher.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/proxy/dispatcher.h
===================================================================
--- ppapi/proxy/dispatcher.h (revision 74733)
+++ ppapi/proxy/dispatcher.h (working copy)
@@ -59,7 +59,7 @@
typedef int32_t (*InitModuleFunc)(PP_Module, GetInterfaceFunc);
typedef void (*ShutdownModuleFunc)();
- ~Dispatcher();
+ virtual ~Dispatcher();
// You must call this function before anything else. Returns true on success.
bool InitWithChannel(MessageLoop* ipc_message_loop,
@@ -79,9 +79,6 @@
VarSerializationRules* serialization_rules() const {
return serialization_rules_.get();
}
- PP_Module pp_module() const {
- return pp_module_;
- }
// Wrapper for calling the local GetInterface function.
const void* GetLocalInterface(const char* interface);
@@ -103,8 +100,9 @@
// IPC::Channel::Listener implementation.
virtual bool OnMessageReceived(const IPC::Message& msg);
+ virtual void OnChannelError();
- // Will be NULL in some unit tests.
+ // Will be NULL in some unit tests and if the remote side has crashed.
IPC::SyncChannel* channel() const {
return channel_.get();
}
@@ -132,19 +130,11 @@
// Takes ownership of the given pointer, which must be on the heap.
void SetSerializationRules(VarSerializationRules* var_serialization_rules);
- void set_pp_module(PP_Module module) {
- pp_module_ = module;
- }
-
bool disallow_trusted_interfaces() const {
return disallow_trusted_interfaces_;
}
private:
- // Set by the derived classed to indicate the module ID corresponding to
- // this dispatcher.
- PP_Module pp_module_;
-
base::ProcessHandle remote_process_handle_; // See getter above.
// When we're unit testing, this will indicate the sink for the messages to
@@ -152,7 +142,8 @@
// indicates that the channel should not be used.
IPC::TestSink* test_sink_;
- // Will be null for some tests when there is a test_sink_.
+ // Will be null for some tests when there is a test_sink_, and if the
+ // remote side has crashed.
scoped_ptr<IPC::SyncChannel> channel_;
bool disallow_trusted_interfaces_;
« no previous file with comments | « ppapi/ppapi_cpp.gypi ('k') | ppapi/proxy/dispatcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698