diff --git a/CHANGELOG.md b/CHANGELOG.md index 3a171afd68..315540c449 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,13 @@ All notable changes to this project will be documented in this file. This project adheres to [Semantic Versioning](https://semver.org/). +## [Unreleased] - ReleaseDate + +### Fixed + +- Relaxed lifetime requirements for `PollFd::new`. + ([#2134](https://github.com/nix-rust/nix/pull/2134)) + ## [0.27.1] - 2023-08-28 ### Fixed diff --git a/src/poll.rs b/src/poll.rs index 9181bf7f30..ffb50762e4 100644 --- a/src/poll.rs +++ b/src/poll.rs @@ -36,7 +36,7 @@ impl<'fd> PollFd<'fd> { // // // Do something with `pollfd`, which uses the CLOSED fd. // ``` - pub fn new(fd: &'fd Fd, events: PollFlags) -> PollFd<'fd> { + pub fn new(fd: Fd, events: PollFlags) -> PollFd<'fd> { PollFd { pollfd: libc::pollfd { fd: fd.as_fd().as_raw_fd(),