ap

An audio player suited to my tastes
Log | Files | Refs | README | LICENSE

commit 9ed5db278ad6b408a299b594acd509ae839c3ff7
parent 630f8cf19951d31b4c271f43c9244680f6c9090b
Author: Jacob R. Edwards <n/a>
Date:   Wed, 27 Oct 2021 17:01:02 -0700

Ignore SIGHUP

Diffstat:
Maps/main.c | 13+++++++------
1 file changed, 7 insertions(+), 6 deletions(-)

diff --git a/aps/main.c b/aps/main.c @@ -118,20 +118,21 @@ main(int argc, char *argv[]) if (aps == NULL) die("unable to setup server"); - error = fork(); - if (error == -1) - die("unable to fork"); - else if (error > 0) - return 0; - aps->coms = commands; aps->ncoms = LEN(commands); signal(SIGCHLD, sigchld); + signal(SIGHUP, SIG_IGN); signal(SIGINT, sigint); signal(SIGQUIT, sigclose); signal(SIGTERM, sigclose); + error = fork(); + if (error == -1) + die("unable to fork"); + else if (error > 0) + return 0; + error = run(aps); if (error == 0) error = aps->close;