]> git.tuebingen.mpg.de Git - paraslash.git/blobdiff - server.c
Simplify SIGUR1 handling.
[paraslash.git] / server.c
index 80cc8f46e36a6e70be2ed13da7bfcce6f5d5a27d..93de8cc35d26c4e9f0e2277a236f47de905d5a6a 100644 (file)
--- a/server.c
+++ b/server.c
@@ -166,7 +166,7 @@ void para_log(int ll, const char* fmt,...)
                fprintf(outfd, "%i: ", ll);
        mypid = getpid();
        if (conf.loglevel_arg <= INFO)
-               fprintf(outfd, "(%d) ", mypid);
+               fprintf(outfd, "(%d) ", (int)mypid);
        va_start(argp, fmt);
        vfprintf(outfd, fmt, argp);
        va_end(argp);
@@ -292,9 +292,9 @@ static void setup_signal_handling(void)
        ret += para_install_sighandler(SIGTERM);
        ret += para_install_sighandler(SIGHUP);
        ret += para_install_sighandler(SIGCHLD);
-       ret += para_install_sighandler(SIGUSR1);
        signal(SIGPIPE, SIG_IGN);
-       if (ret != 5) {
+       signal(SIGUSR1, SIG_IGN);
+       if (ret != 4) {
                PARA_EMERG_LOG("%s", "could not install signal handlers\n");
                exit(EXIT_FAILURE);
        }