audioc: Switch to blocking file descriptors.
[paraslash.git] / server.c
index ba5dabde066050825a46ef3abae82556474e7226..bc143039563b830b07164efd96ac76a4f6d3e267 100644 (file)
--- a/server.c
+++ b/server.c
@@ -276,16 +276,13 @@ static void handle_sighup(void)
                kill(mmd->afs_pid, SIGHUP);
 }
 
-static void signal_post_select(struct sched *s, struct task *t)
+static void signal_post_select(struct sched *s, __a_unused struct task *t)
 {
-       struct signal_task *st = container_of(t, struct signal_task, task);
-       int signum;
-
-       if (!FD_ISSET(st->fd, &s->rfds))
-               return;
+       int signum = para_next_signal(&s->rfds);
 
-       signum = para_next_signal();
        switch (signum) {
+       case 0:
+               return;
        case SIGHUP:
                handle_sighup();
                break;