aboutsummaryrefslogtreecommitdiff
path: root/kernel/fs
diff options
context:
space:
mode:
authorNathan Benavides-Luu <nate1299@me.com>2024-04-22 20:27:07 -0400
committerGitHub <noreply@github.com>2024-04-22 20:27:07 -0400
commite1e99d4adb0fcf86c9745c703b4e3ffb1261440b (patch)
tree3aed533435b917c9f7851601143f186070c54b7f /kernel/fs
parent6ddcbbd59f0a04eee2b163930fc86d74dd2434ec (diff)
add delete_pframe call to s5_free_block (#10)
Diffstat (limited to 'kernel/fs')
-rw-r--r--kernel/fs/s5fs/s5fs_subr.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/kernel/fs/s5fs/s5fs_subr.c b/kernel/fs/s5fs/s5fs_subr.c
index 33b03c9..27b6a92 100644
--- a/kernel/fs/s5fs/s5fs_subr.c
+++ b/kernel/fs/s5fs/s5fs_subr.c
@@ -268,6 +268,9 @@ static void s5_free_block(s5fs_t *s5fs, blocknum_t blockno)
else
{
s->s5s_free_blocks[s->s5s_nfree++] = blockno;
+ // only delete in this case b/c in first case we're still using that
+ // block as a "meta" block, just to store free block numbers
+ mobj_delete_pframe(&s5fs->s5f_mobj, blockno);
}
s5_unlock_super(s5fs);
}