Skip to content
Snippets Groups Projects
Commit d2bd4e4b authored by Simon McVittie's avatar Simon McVittie
Browse files

launcher-service: Unblock and unignore all signals during startup

Steam could run this tool in an arbitrary environment, with necessary
signals either blocked (sigprocmask() or similar), or ignored
(sigaction() with action SIG_IGN, or similar). Both of these are
inherited across fork() and execve() by default, and current versions
of Steam do block SIGCHLD in practice.

However, blocking or ignoring SIGCHLD breaks handling of subprocesses,
which is particularly critical for s-r-launcher-service: that prevents
it from detecting that its child processes have exited, causing
s-r-launch-client to hang forever, which in turn breaks startup of
SteamVR on systems where /bin/sh is dash (but not bash, which apparently
resets the disposition of SIGCHLD internally).

steamrt/tasks#354,
https://github.com/ValveSoftware/SteamVR-for-Linux/issues/618



Signed-off-by: default avatarSimon McVittie <smcv@collabora.com>
parent 8a78a235
No related branches found
No related tags found
No related merge requests found
......@@ -1622,6 +1622,10 @@ main (int argc,
goto out;
}
/* Must be before pv_launcher_server_connect_to_signals() which partially
* undoes this */
_srt_unblock_signals ();
server->purpose = opt_purpose;
if (opt_verbose || opt_hint)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment