Add redox_cur_procfd_v0 method to get own proc_fd

This commit is contained in:
bjorn3
2025-04-20 16:19:45 +02:00
parent 040009ab3d
commit 4755d1ae24
+5
View File
@@ -367,6 +367,11 @@ pub unsafe extern "C" fn redox_mkns_v1(
}
// ABI-UNSTABLE
#[no_mangle]
pub unsafe extern "C" fn redox_cur_procfd_v0() -> usize {
**redox_rt::current_proc_fd()
}
#[no_mangle]
pub unsafe extern "C" fn redox_cur_thrfd_v0() -> usize {
**redox_rt::RtTcb::current().thread_fd()