Skip to content

Commit

Permalink
Merge pull request #145 from uklotzde/linux-deps
Browse files Browse the repository at this point in the history
Update Linux dependencies
  • Loading branch information
ruabmbua authored Jan 28, 2024
2 parents 6bbbbe2 + e6b66bc commit 17a1fb2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,8 @@ libc = "0.2"
cfg-if = "1"

[target.'cfg(target_os = "linux")'.dependencies]
udev = { version = "0.7", optional = true }
nix = { version = "0.26", optional = true }
udev = { version = "0.8", optional = true }
nix = { version = "0.27", optional = true, features = ["fs", "ioctl", "poll"] }

[target.'cfg(windows)'.dependencies]
windows-sys = { version = "0.48", features = ["Win32_Foundation"] }
Expand Down
2 changes: 1 addition & 1 deletion src/linux_native.rs
Original file line number Diff line number Diff line change
Expand Up @@ -489,7 +489,7 @@ impl HidDeviceBackendBase for HidDevice {
}

fn read_timeout(&self, buf: &mut [u8], timeout: i32) -> HidResult<usize> {
let pollfd = PollFd::new(self.fd.as_raw_fd(), PollFlags::POLLIN);
let pollfd = PollFd::new(&self.fd, PollFlags::POLLIN);
let res = poll(&mut [pollfd], timeout)?;

if res == 0 {
Expand Down

0 comments on commit 17a1fb2

Please sign in to comment.