projects
/
platform
/
upstream
/
systemd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
33d11a2
)
udevadm: exiting udevadm monitor normally under SIGTERM or SIGINT
author
huyubiao
<huyubiao@huawei.com>
Fri, 24 Nov 2023 06:43:43 +0000
(14:43 +0800)
committer
Yu Watanabe
<watanabe.yu+github@gmail.com>
Sat, 25 Nov 2023 03:53:10 +0000
(12:53 +0900)
Under SIGTERM or SIGINT, exit event and release resources, and exit udevadm monitor normally.
src/udev/udevadm-monitor.c
patch
|
blob
|
history
diff --git
a/src/udev/udevadm-monitor.c
b/src/udev/udevadm-monitor.c
index
138b4be
..
27c4853
100644
(file)
--- a/
src/udev/udevadm-monitor.c
+++ b/
src/udev/udevadm-monitor.c
@@
-208,7
+208,7
@@
int monitor_main(int argc, char *argv[], void *userdata) {
goto finalize;
}
- assert_se(sigprocmask_many(SIG_
UN
BLOCK, NULL, SIGTERM, SIGINT, -1) >= 0);
+ assert_se(sigprocmask_many(SIG_BLOCK, NULL, SIGTERM, SIGINT, -1) >= 0);
(void) sd_event_add_signal(event, NULL, SIGTERM, NULL, NULL);
(void) sd_event_add_signal(event, NULL, SIGINT, NULL, NULL);