Skip to content

Commit

Permalink
Fix containerd shim
Browse files Browse the repository at this point in the history
Signed-off-by: Maksym Pavlenko <[email protected]>
  • Loading branch information
mxpv committed Mar 14, 2024
1 parent 798ab74 commit 66e513a
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions crates/shim/src/synchronous/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@ cfg_unix! {
use signal_hook::iterator::Signals;
use std::os::unix::fs::FileTypeExt;
use std::{convert::TryFrom, fs, path::Path};
use std::os::fd::AsRawFd;
}

cfg_windows! {
Expand Down Expand Up @@ -499,7 +498,7 @@ pub fn spawn(opts: StartOpts, grouping: &str, vars: Vec<(&str, &str)>) -> Result
.stdin(Stdio::null())
.stderr(Stdio::null())
.fd_mappings(vec![FdMapping {
parent_fd: _listener.as_raw_fd(),
parent_fd: _listener.into(),
child_fd: SOCKET_FD,
}])?;

Expand All @@ -508,7 +507,6 @@ pub fn spawn(opts: StartOpts, grouping: &str, vars: Vec<(&str, &str)>) -> Result
.map_err(io_error!(e, "spawn shim"))
.map(|child| {
// Ownership of `listener` has been passed to child.
std::mem::forget(_listener);
(child.id(), address)
})
}
Expand Down

0 comments on commit 66e513a

Please sign in to comment.