pub fn close<Fd: IntoRawFd>(fd: Fd) -> Result<()>
Close a file descriptor.
If fd is an owned file descriptor, it is generally preferred to call drop(fd) rather than close(fd).
fd
drop(fd)
close(fd)