diff options
author | Derek Foreman <derekf@osg.samsung.com> | 2017-07-25 16:17:36 -0500 |
---|---|---|
committer | Pekka Paalanen <pekka.paalanen@collabora.co.uk> | 2017-07-27 12:05:19 +0300 |
commit | f981d69553f52ca50aaf864bf821bb022ab7da82 (patch) | |
tree | 19caf3ec2051388046a1f5cba9e0c233982d7ee1 | |
parent | c623902ecaa191c7eccfcb7c212313407da82c56 (diff) |
logind: actually close fd in launcher_logind_close
We still need to close fds passed to us - or we leak quite a few fds
on VC switch.
Regression, originally fixed in 8f5acc2f3a29c3831af4ddd6bed57f703c98dc77
and re-broken in commit 72dea06d7952e3ce8dd8057f7106186da4fa2678
but only for the logind launcher.
Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
-rw-r--r-- | libweston/launcher-logind.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/libweston/launcher-logind.c b/libweston/launcher-logind.c index f10a2831..a069bd4f 100644 --- a/libweston/launcher-logind.c +++ b/libweston/launcher-logind.c @@ -216,6 +216,7 @@ launcher_logind_close(struct weston_launcher *launcher, int fd) int r; r = fstat(fd, &st); + close(fd); if (r < 0) { weston_log("logind: cannot fstat fd: %m\n"); return; |