fix some snafoos
git-svn-id: https://svn.musicpd.org/mpd/trunk@678 09075e82-0dd4-0310-85a5-a0d7c8717e4f
This commit is contained in:
parent
4844e05e65
commit
30d9589cb3
@ -30,6 +30,7 @@
|
|||||||
#include "interface.h"
|
#include "interface.h"
|
||||||
#include "volume.h"
|
#include "volume.h"
|
||||||
#include "mpd_types.h"
|
#include "mpd_types.h"
|
||||||
|
#include "sig_handlers.h"
|
||||||
|
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
@ -130,6 +131,7 @@ int updateInit(FILE * fp) {
|
|||||||
sigaction(SIGPIPE,&sa,NULL);
|
sigaction(SIGPIPE,&sa,NULL);
|
||||||
sigaction(SIGCHLD,&sa,NULL);
|
sigaction(SIGCHLD,&sa,NULL);
|
||||||
|
|
||||||
|
finishSigHandlers();
|
||||||
close(listenSocket);
|
close(listenSocket);
|
||||||
freeAllInterfaces();
|
freeAllInterfaces();
|
||||||
finishPlaylist();
|
finishPlaylist();
|
||||||
|
@ -141,7 +141,6 @@ void initPlaylist() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void finishPlaylist() {
|
void finishPlaylist() {
|
||||||
clearPlaylist(stderr);
|
|
||||||
free(playlist.songs);
|
free(playlist.songs);
|
||||||
playlist.songs = NULL;
|
playlist.songs = NULL;
|
||||||
free(playlist.order);
|
free(playlist.order);
|
||||||
|
@ -63,9 +63,6 @@ void initSigHandlers() {
|
|||||||
sigaction(SIGPIPE,&sa,NULL);
|
sigaction(SIGPIPE,&sa,NULL);
|
||||||
sa.sa_handler = usr1SigHandler;
|
sa.sa_handler = usr1SigHandler;
|
||||||
sigaction(SIGUSR1,&sa,NULL);
|
sigaction(SIGUSR1,&sa,NULL);
|
||||||
sigaddset(&sa.sa_mask,SIGTERM);
|
|
||||||
sigaddset(&sa.sa_mask,SIGHUP);
|
|
||||||
sigaddset(&sa.sa_mask,SIGCHLD);
|
|
||||||
sa.sa_handler = chldSigHandler;
|
sa.sa_handler = chldSigHandler;
|
||||||
sigaction(SIGCHLD,&sa,NULL);
|
sigaction(SIGCHLD,&sa,NULL);
|
||||||
sa.sa_handler = hupSigHandler;
|
sa.sa_handler = hupSigHandler;
|
||||||
|
Loading…
Reference in New Issue
Block a user