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

Unified Diff: ppapi/native_client/src/trusted/plugin/pnacl_translate_thread.h

Issue 10843009: Better handling of surfaway/reload in PNaCl translation (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 5 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: ppapi/native_client/src/trusted/plugin/pnacl_translate_thread.h
diff --git a/ppapi/native_client/src/trusted/plugin/pnacl_translate_thread.h b/ppapi/native_client/src/trusted/plugin/pnacl_translate_thread.h
index 0f7f592165ba87f4621d3f129a462492f61c2ab4..2de028f1d2b8b705fd7a28886540ada85b529275 100644
--- a/ppapi/native_client/src/trusted/plugin/pnacl_translate_thread.h
+++ b/ppapi/native_client/src/trusted/plugin/pnacl_translate_thread.h
@@ -11,6 +11,7 @@
#include "native_client/src/shared/platform/nacl_threads.h"
#include "native_client/src/shared/platform/nacl_sync_checked.h"
#include "native_client/src/trusted/plugin/plugin_error.h"
+#include "native_client/src/trusted/plugin/service_runtime.h"
#include "ppapi/cpp/completion_callback.h"
@@ -64,6 +65,13 @@ class PnaclTranslateThread {
const nacl::string& soname,
const nacl::string& lib_dependencies);
+ // Register a reverse service interface which will be shutdown if the
+ // plugin is shutdown. The reverse service pointer must be available on the
+ // main thread because the translation thread could be blocked on SRPC
+ // waiting for the translator, which could be waiting on a reverse
+ // service call.
+ void RegisterReverseInterface(PluginReverseInterface *interface);
+
// Callback to run when tasks are completed or an error has occurred.
pp::CompletionCallback report_translate_finished_;
// True if the translation thread and related subprocesses should exit.
@@ -73,6 +81,9 @@ class PnaclTranslateThread {
nacl::scoped_ptr<NaClThread> translate_thread_;
+ // Reverse interface to shutdown on SetSubprocessesShouldDie
+ PluginReverseInterface *current_rev_interface_;
robertm 2012/07/31 17:22:18 "*" to the left
Derek Schuff 2012/07/31 17:41:28 Done.
+
// Data about the translation files, owned by the coordinator
const Manifest* manifest_;
const Manifest* ld_manifest_;

Powered by Google App Engine
This is Rietveld 408576698