mirror of
https://github.com/Cloudef/bemenu
synced 2024-11-22 17:02:05 +01:00
Move SIGCHLD to client launch
This commit is contained in:
parent
9a7b736dd9
commit
c0c608cad7
@ -1,6 +1,7 @@
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include <signal.h>
|
||||
#include <unistd.h>
|
||||
#include <dirent.h>
|
||||
#include <assert.h>
|
||||
@ -132,6 +133,14 @@ static inline void ignore_ret(int useless, ...) { (void)useless; }
|
||||
static void
|
||||
launch(const struct client *client, const char *bin)
|
||||
{
|
||||
struct sigaction action = {
|
||||
.sa_handler = SIG_DFL,
|
||||
.sa_flags = SA_NOCLDWAIT
|
||||
};
|
||||
|
||||
// do not care about childs
|
||||
sigaction(SIGCHLD, &action, NULL);
|
||||
|
||||
if (!bin)
|
||||
return;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user