fix some signal handling

git-svn-id: https://svn.musicpd.org/mpd/trunk@3101 09075e82-0dd4-0310-85a5-a0d7c8717e4f
This commit is contained in:
Warren Dukes
2005-03-19 12:28:47 +00:00
parent d392b7e48b
commit 9193766c06
3 changed files with 13 additions and 15 deletions

View File

@@ -44,9 +44,7 @@ void decodeSigHandler(int sig, siginfo_t * si, void * v) {
int status;
if(decode_pid==wait3(&status,WNOHANG,NULL)) {
if(WIFSIGNALED(status)) {
if(WTERMSIG(status)!=SIGTERM &&
WTERMSIG(status)!=SIGINT)
{
if(WTERMSIG(status)!=SIGTERM) {
ERROR("decode process died from "
"signal: %i\n",
WTERMSIG(status));
@@ -65,12 +63,6 @@ void decodeSigHandler(int sig, siginfo_t * si, void * v) {
else DEBUG("decoder (or child) got SIGTERM\n");
exit(EXIT_SUCCESS);
}
else if(sig==SIGINT) {
if(decode_pid > 0) {
DEBUG("player (or child) got SIGINT\n");
}
else DEBUG("decoder (or child) got SIGINT\n");
}
}
void stopDecode(DecoderControl * dc) {