diff --git a/redox-rt/src/arch/aarch64.rs b/redox-rt/src/arch/aarch64.rs
index c9aaccbfe685de00b42b8d04103c9d2011a1e1b7..02ac5341534c374f7876e64f8bad112347b3686b 100644
--- a/redox-rt/src/arch/aarch64.rs
+++ b/redox-rt/src/arch/aarch64.rs
@@ -5,7 +5,7 @@ use syscall::{data::*, error::*};
 use crate::{
     proc::{fork_inner, FdGuard},
     signal::{inner_c, RtSigarea, SigStack, PROC_CONTROL_STRUCT},
-    Tcb,
+    RtTcb, Tcb,
 };
 
 // Setup a stack starting from the very end of the address space, and then growing downwards.
@@ -99,7 +99,11 @@ unsafe extern "C" fn fork_impl(initial_rsp: *mut usize) -> usize {
 
 unsafe extern "C" fn child_hook(cur_filetable_fd: usize, new_pid_fd: usize) {
     let _ = syscall::close(cur_filetable_fd);
-    let _ = syscall::close(new_pid_fd);
+    // TODO: Currently pidfd == threadfd, but this will not be the case later.
+    RtTcb::current()
+        .thr_fd
+        .get()
+        .write(Some(FdGuard::new(new_pid_fd)));
 }
 
 asmfunction!(__relibc_internal_fork_wrapper -> usize: ["