Skip to content

Commit

Permalink
unix: swap out mutable slice for array
Browse files Browse the repository at this point in the history
  • Loading branch information
Xaeroxe committed Nov 18, 2021
1 parent bec4ef6 commit da99fca
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/platform/unix/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1070,7 +1070,7 @@ impl UnixCmsg {
},
BlockingMode::Timeout(duration) => {
let events = libc::POLLIN | libc::POLLPRI | libc::POLLRDHUP;
let fd = &mut [libc::pollfd {fd, events, revents: 0}];
let mut fd = [libc::pollfd {fd, events, revents: 0}];
let result = libc::poll(
fd.as_mut_ptr(),
fd.len() as libc::c_ulong,
Expand Down

0 comments on commit da99fca

Please sign in to comment.