Add pipe2

This commit is contained in:
Jeremy Soller
2019-04-28 09:13:24 -06:00
parent 68c4e95b6d
commit dd9328bd41
4 changed files with 11 additions and 6 deletions
+6 -1
View File
@@ -421,7 +421,12 @@ pub extern "C" fn pause() -> c_int {
#[no_mangle]
pub unsafe extern "C" fn pipe(fildes: *mut c_int) -> c_int {
Sys::pipe(slice::from_raw_parts_mut(fildes, 2))
pipe2(fildes, 0)
}
#[no_mangle]
pub unsafe extern "C" fn pipe2(fildes: *mut c_int, flags: c_int) -> c_int {
Sys::pipe2(slice::from_raw_parts_mut(fildes, 2), flags)
}
#[no_mangle]