[smart] fixup of lwp recycling and mm varea (#8206)

Signed-off-by: shell <wangxiaoyao@rt-thread.com>
Signed-off-by: Shell <smokewood@qq.com>
Co-authored-by: xqyjlj <xqyjlj@126.com>
This commit is contained in:
Shell
2023-11-02 20:23:11 +08:00
committed by GitHub
parent 1b6f0e88a3
commit c2036e769a
17 changed files with 464 additions and 297 deletions

View File

@@ -295,6 +295,10 @@ void fdt_fd_release(struct dfs_fdtable *fdt, int fd)
if (file && file->ref_count == 1)
{
rt_mutex_detach(&file->pos_lock);
if (file->mmap_context)
{
rt_free(file->mmap_context);
}
rt_free(file);
}
else