mirror of
https://github.com/systemd/systemd-stable.git
synced 2024-12-28 07:21:32 +03:00
bus_open leak sd_event_source when udevadm trigger。
On my host, when executing the udevadm trigger, I only receive the change event, which causes memleak
This commit is contained in:
parent
1f7b6872db
commit
b2774a3ae6
@ -341,7 +341,8 @@ int button_open(Button *b) {
|
||||
}
|
||||
|
||||
(void) button_set_mask(b);
|
||||
|
||||
|
||||
b->io_event_source = sd_event_source_unref(b->io_event_source);
|
||||
r = sd_event_add_io(b->manager->event, &b->io_event_source, b->fd, EPOLLIN, button_dispatch, b);
|
||||
if (r < 0) {
|
||||
log_error_errno(r, "Failed to add button event: %m");
|
||||
|
Loading…
Reference in New Issue
Block a user