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

Unified Diff: mojo/edk/embedder/embedder.h

Issue 2043713004: Mojo: Add NotifyBadMessage API (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: no bindings Created 4 years, 6 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 | « no previous file | mojo/edk/embedder/embedder.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/edk/embedder/embedder.h
diff --git a/mojo/edk/embedder/embedder.h b/mojo/edk/embedder/embedder.h
index 68c198b7067a1aa27eb914d12edc9abb6a34e72b..3a4747b799c61b46b897208bda5fd8610129ab46 100644
--- a/mojo/edk/embedder/embedder.h
+++ b/mojo/edk/embedder/embedder.h
@@ -29,6 +29,8 @@ namespace edk {
class ProcessDelegate;
+using ProcessErrorCallback = base::Callback<void(const std::string& error)>;
+
// Basic configuration/initialization ------------------------------------------
// |Init()| sets up the basic Mojo system environment, making the |Mojo...()|
@@ -44,6 +46,16 @@ MOJO_SYSTEM_IMPL_EXPORT void ChildProcessLaunched(
ScopedPlatformHandle server_pipe,
const std::string& child_token);
+// Called in the parent process for each child process that is launched.
+// |process_error_callback| is called if the system becomes aware of some
+// internal error related to this process, e.g., if the system is notified of a
+// bad message from this process via the |MojoNotifyBadMessage()| API.
+MOJO_SYSTEM_IMPL_EXPORT void ChildProcessLaunched(
+ base::ProcessHandle child_process,
+ ScopedPlatformHandle server_pipe,
+ const std::string& child_token,
+ const ProcessErrorCallback& error_callback);
+
// Called in the parent process when a child process fails to launch.
// Exactly one of ChildProcessLaunched() or ChildProcessLaunchFailed() must be
// called per child process launch attempt.
« no previous file with comments | « no previous file | mojo/edk/embedder/embedder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698