mirror of
https://github.com/robbert-vdh/yabridge.git
synced 2026-05-08 12:30:12 +02:00
Pass the PID of the native host to the Wine hosts
We need this for our watchdog.
This commit is contained in:
@@ -76,7 +76,8 @@ class PluginBridge {
|
||||
HostRequest{
|
||||
.plugin_type = plugin_type,
|
||||
.plugin_path = info.windows_plugin_path.string(),
|
||||
.endpoint_base_dir = sockets.base_dir.string()},
|
||||
.endpoint_base_dir = sockets.base_dir.string(),
|
||||
.parent_pid = getpid()},
|
||||
sockets,
|
||||
*config.group))
|
||||
: std::unique_ptr<HostProcess>(
|
||||
@@ -88,7 +89,8 @@ class PluginBridge {
|
||||
.plugin_type = plugin_type,
|
||||
.plugin_path =
|
||||
info.windows_plugin_path.string(),
|
||||
.endpoint_base_dir = sockets.base_dir.string()},
|
||||
.endpoint_base_dir = sockets.base_dir.string(),
|
||||
.parent_pid = getpid()},
|
||||
sockets))),
|
||||
has_realtime_priority(has_realtime_priority_promise.get_future()),
|
||||
wine_io_handler([&]() {
|
||||
|
||||
@@ -83,6 +83,10 @@ IndividualHost::IndividualHost(boost::asio::io_context& io_context,
|
||||
host_request.plugin_path,
|
||||
#endif
|
||||
host_request.endpoint_base_dir,
|
||||
// We pass this process' process ID as an argument so we can run a
|
||||
// watchdog on the Wine plugin host process that shuts down the
|
||||
// sockets after this process shuts down
|
||||
std::to_string(getpid()),
|
||||
bp::env = plugin_info.create_host_env(),
|
||||
bp::std_out = stdout_pipe,
|
||||
bp::std_err = stderr_pipe
|
||||
|
||||
Reference in New Issue
Block a user