[−][src]Function linux::syscall::dup3
pub fn dup3(oldfd: c_int, newfd: c_int, flags: c_int) -> c_int
Duplicates a file descriptor by replacing another one.
[argument, oldfd] The file descriptor to duplicate.
[argument, newfd] The file descriptor to replace.
[argument, flags] Flags to use when creating the new file descriptor.
= Remarks
Unless lrs was compiled with the no-auto-cloexec
flag, this function automatically
adds the O_CLOEXEC
flag.
= See also
- link:man:dup3(2)