mirror of
https://github.com/asterinas/asterinas.git
synced 2025-06-20 13:06:33 +00:00
Drop files at the correct time
This commit is contained in:
committed by
Tate, Hongliang Tian
parent
7e1abc1fbb
commit
8600278a5f
@ -15,7 +15,7 @@ use crate::{
|
||||
pub fn sys_fstat(fd: FileDesc, stat_buf_ptr: Vaddr, ctx: &Context) -> Result<SyscallReturn> {
|
||||
debug!("fd = {}, stat_buf_addr = 0x{:x}", fd, stat_buf_ptr);
|
||||
|
||||
let mut file_table = ctx.thread_local.file_table().borrow_mut();
|
||||
let mut file_table = ctx.thread_local.borrow_file_table_mut();
|
||||
let file = get_file_fast!(&mut file_table, fd);
|
||||
|
||||
let stat = Stat::from(file.metadata());
|
||||
|
Reference in New Issue
Block a user