mirror of
https://github.com/drasko/codezero.git
synced 2026-03-14 00:01:50 +01:00
tcb_destroy() in pager and fs0 now caters for shared structures.
This commit is contained in:
@@ -148,6 +148,11 @@ void tcb_destroy(struct tcb *task)
|
||||
{
|
||||
global_remove_task(task);
|
||||
|
||||
if (--task->fs_data->tcb_refs == 0)
|
||||
kfree(task->fs_data);
|
||||
if (--task->files->tcb_refs == 0)
|
||||
kfree(task->files);
|
||||
|
||||
kfree(task);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user