Index: components/browser_watcher/watcher_client_win.h |
diff --git a/components/browser_watcher/watcher_client_win.h b/components/browser_watcher/watcher_client_win.h |
index 5ae3c96f2a4393caf5e5fc7a01cd6ba4fef76d88..9e8810799ba16a154a2c019a0a69a667c0b73fa7 100644 |
--- a/components/browser_watcher/watcher_client_win.h |
+++ b/components/browser_watcher/watcher_client_win.h |
@@ -32,12 +32,19 @@ class WatcherClient { |
// a non-threadsafe legacy launch mode that's compatible with Windows XP. |
void LaunchWatcher(); |
+ // Ensures that |handle| may be inherited by the watcher process. |handle| |
+ // must still be inheritable, and it's the client's responsibility to |
+ // communicate the value of |handle| to the launched process. |
+ void AddInheritedHandle(HANDLE handle); |
+ |
+ // Returns the launched process. |
+ const base::Process& process() const { return process_; } |
+ |
// Accessors, exposed only for testing. |
bool use_legacy_launch() const { return use_legacy_launch_; } |
void set_use_legacy_launch(bool use_legacy_launch) { |
use_legacy_launch_ = use_legacy_launch; |
} |
- base::ProcessHandle process() const { return process_.Handle(); } |
private: |
// If true, the watcher process will be launched with XP legacy handle |
@@ -52,6 +59,8 @@ class WatcherClient { |
// LaunchWatcher() call. |
base::Process process_; |
+ std::vector<HANDLE> inherited_handles_; |
+ |
DISALLOW_COPY_AND_ASSIGN(WatcherClient); |
}; |