pub fn dup2(old_fd: usize, new_fd: usize) -> Result<usize>
Duplicate a file descriptor to a specific number (POSIX dup2).