libcore: Implement a dup2

This commit is contained in:
Patrick Walton 2012-08-21 16:00:14 -07:00
parent 8b8e0c2a45
commit 9440f8e9b8

View File

@ -357,6 +357,10 @@ fn pipe() -> {in: c_int, out: c_int} {
return {in: fds.in, out: fds.out};
}
fn dup2(src: c_int, dst: c_int) -> c_int {
libc::dup2(src, dst)
}
fn dll_filename(base: ~str) -> ~str {
return pre() + base + dll_suffix();