Skip to content
This repository has been archived by the owner on May 12, 2021. It is now read-only.

Commit

Permalink
agent: fix epoll fd left in the kata-agent when exec process
Browse files Browse the repository at this point in the history
reason: If someone want to exec a process in the container, kata-agent will
create a epollfd to monitor the pts fd event. However epollfd is not closed
when exec process exit, which cause fd is left in the kata-agent process.

fixes: #762

Signed-off-by: jiangpengfei <[email protected]>
  • Loading branch information
flyflypeng committed Mar 17, 2020
1 parent 2725dda commit 8325ad8
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions agent.go
Original file line number Diff line number Diff line change
Expand Up @@ -254,6 +254,7 @@ func (p *process) closePostExitFDs() {

if p.epoller != nil {
p.epoller.sockR.Close()
unix.Close(p.epoller.fd)
}
}

Expand Down

0 comments on commit 8325ad8

Please sign in to comment.