manager: remove timer fd explicitly from epoll

Forked processes can keep the old fd alive triggering epoll over and
over again else.

https://bugs.freedesktop.org/show_bug.cgi?id=61697
This commit is contained in:
Enrico Scholz 2013-03-02 17:31:53 +01:00 committed by Lennart Poettering
parent 95f1b47d27
commit f1324eaa68

View file

@ -1674,6 +1674,8 @@ static int process_event(Manager *m, struct epoll_event *ev) {
NULL);
/* Restart the watch */
epoll_ctl(m->epoll_fd, EPOLL_CTL_DEL, m->time_change_watch.fd,
NULL);
close_nointr_nofail(m->time_change_watch.fd);
watch_init(&m->time_change_watch);
manager_setup_time_change(m);