Commit 98022748f6c7bce85b9f123fd4d1a621219dd8d9

Authored by Al Viro
1 parent 31605debdf

eventpoll: use-after-possible-free in epoll_create1()

As soon as we'd installed the file into descriptor table, it can
get closed by another thread.  Freeing ep in process...

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>

Showing 1 changed file with 1 additions and 1 deletions Side-by-side Diff

... ... @@ -1654,8 +1654,8 @@
1654 1654 error = PTR_ERR(file);
1655 1655 goto out_free_fd;
1656 1656 }
1657   - fd_install(fd, file);
1658 1657 ep->file = file;
  1658 + fd_install(fd, file);
1659 1659 return fd;
1660 1660  
1661 1661 out_free_fd: