X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=udev%2Fudevd.c;h=2eb914a3f335f61952b355328ef9c8fae707b559;hb=6068553195f43a2fd7987c48178de23b63a09f15;hp=4024460d4b1de82faa486dbd0da8e0d9a85dcae7;hpb=f7c5b04f69e004912327f082be8645b65bb1ff5d;p=elogind.git diff --git a/udev/udevd.c b/udev/udevd.c index 4024460d4..2eb914a3f 100644 --- a/udev/udevd.c +++ b/udev/udevd.c @@ -79,6 +79,7 @@ static bool stop_exec_queue; static bool reload_config; static int max_childs; static int childs; +static sigset_t orig_sigmask; static struct udev_list_node event_list; static struct udev_list_node worker_list; static bool udev_exit; @@ -292,7 +293,8 @@ static void worker_new(struct event *event) /* execute RUN= */ if (err == 0 && !udev_event->ignore_device && udev_get_run(udev_event->udev)) - failed = udev_event_execute_run(udev_event); + failed = udev_event_execute_run(udev_event, + &orig_sigmask); /* reset alarm */ alarm(0); @@ -776,7 +778,7 @@ static void startup_log(struct udev *udev) if (f != NULL) fprintf(f, "<3>%s\n", depr_str); err(udev, "%s\n", depr_str); - sleep(3); + sleep(15); } if (f != NULL) @@ -926,7 +928,7 @@ int main(int argc, char *argv[]) /* block and listen to all signals on signalfd */ sigfillset(&mask); - sigprocmask(SIG_SETMASK, &mask, NULL); + sigprocmask(SIG_SETMASK, &mask, &orig_sigmask); pfd[FD_SIGNAL].fd = signalfd(-1, &mask, 0); if (pfd[FD_SIGNAL].fd < 0) { fprintf(stderr, "error getting signalfd\n");