mirror of
https://github.com/clearlinux/systemd-stable.git
synced 2026-10-15 10:05:28 +00:00
Revert "udevd: simplify sigterm check"
This reverts commit 47e737dc13 - it
introduced a use-after-free. The only way the code would get simpler
is with a cleanup function, but eh, not worth it for just this one
bit.
Reviewed by kay on IRC.
This commit is contained in:
+5
-3
@@ -314,10 +314,12 @@ static void worker_new(struct event *event)
|
||||
udev_device_unref(dev);
|
||||
dev = NULL;
|
||||
|
||||
udev_event_unref(udev_event);
|
||||
|
||||
if (udev_event->sigterm)
|
||||
if (udev_event->sigterm) {
|
||||
udev_event_unref(udev_event);
|
||||
goto out;
|
||||
}
|
||||
|
||||
udev_event_unref(udev_event);
|
||||
|
||||
/* wait for more device messages from main udevd, or term signal */
|
||||
while (dev == NULL) {
|
||||
|
||||
Reference in New Issue
Block a user