[LibOS] Fix handle leak in epoll_ctl

This commit is contained in:
Martin Schmatz
2019-07-27 19:28:01 -07:00
committed by Dmitrii Kuvaiskii
parent bd46625395
commit 38bd8ba208
+3 -1
View File
@@ -256,11 +256,13 @@ int shim_do_epoll_ctl (int epfd, int op, int fd,
lock(&hdl->lock);
LISTP_DEL(epoll_fd, &hdl->epolls, back);
unlock(&hdl->lock);
put_handle(epoll_hdl);
debug("delete handle %p from epoll handle %p\n",
hdl, epoll);
put_handle(epoll_hdl);
put_handle(hdl);
LISTP_DEL(epoll_fd, &epoll->fds, list);
epoll->nfds--;
free(epoll_fd);