mirror of
https://github.com/hyprwm/Hyprland
synced 2024-12-26 12:49:50 +01:00
reset sigmask on fork
This commit is contained in:
parent
0508c7d384
commit
922e978f56
2 changed files with 10 additions and 0 deletions
|
@ -379,6 +379,11 @@ void CConfigManager::handleRawExec(const std::string& command, const std::string
|
|||
if (child == 0) {
|
||||
// run in child
|
||||
grandchild = fork();
|
||||
|
||||
sigset_t set;
|
||||
sigemptyset(&set);
|
||||
sigprocmask(SIG_SETMASK, &set, NULL);
|
||||
|
||||
if (grandchild == 0) {
|
||||
// run in grandchild
|
||||
close(socket[0]);
|
||||
|
|
|
@ -500,6 +500,11 @@ void CKeybindManager::spawn(std::string args) {
|
|||
}
|
||||
if (child == 0) {
|
||||
// run in child
|
||||
|
||||
sigset_t set;
|
||||
sigemptyset(&set);
|
||||
sigprocmask(SIG_SETMASK, &set, NULL);
|
||||
|
||||
grandchild = fork();
|
||||
if (grandchild == 0) {
|
||||
// run in grandchild
|
||||
|
|
Loading…
Reference in a new issue