summaryrefslogtreecommitdiff
path: root/udev/udevadm-settle.c
diff options
context:
space:
mode:
Diffstat (limited to 'udev/udevadm-settle.c')
-rw-r--r--udev/udevadm-settle.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/udev/udevadm-settle.c b/udev/udevadm-settle.c
index 5030f18602..4f422f9092 100644
--- a/udev/udevadm-settle.c
+++ b/udev/udevadm-settle.c
@@ -66,6 +66,7 @@ int udevadm_settle(struct udev *udev, int argc, char *argv[])
const char *exists = NULL;
int timeout = DEFAULT_TIMEOUT;
struct sigaction act;
+ sigset_t mask;
struct udev_queue *udev_queue = NULL;
int rc = 1;
@@ -78,6 +79,10 @@ int udevadm_settle(struct udev *udev, int argc, char *argv[])
act.sa_flags = 0;
sigaction(SIGALRM, &act, NULL);
sigaction(SIGUSR1, &act, NULL);
+ sigemptyset(&mask);
+ sigaddset(&mask, SIGUSR1);
+ sigaddset(&mask, SIGALRM);
+ sigprocmask(SIG_UNBLOCK, &mask, NULL);
while (1) {
int option;
@@ -163,7 +168,7 @@ int udevadm_settle(struct udev *udev, int argc, char *argv[])
uctrl = udev_ctrl_new_from_socket(udev, UDEV_CTRL_SOCK_PATH);
if (uctrl != NULL) {
- sigset_t mask, oldmask;
+ sigset_t oldmask;
sigemptyset(&mask);
sigaddset(&mask, SIGUSR1);