diff --git a/src/memory/memory.c b/src/memory/memory.c index fef2605..87d739d 100644 --- a/src/memory/memory.c +++ b/src/memory/memory.c @@ -113,13 +113,13 @@ static void add_frame_node(multiboot_memory_map_t *mmmt) nb_frame = ((size * 8) / (PAGE_SIZE * 8 + 1)) */ const uint32_t nb_frame = ((len * 8) / (PAGE_SIZE * 8 + 1)); - current->first_free_frame = 0; current->next = NULL; current->remaining_frames = nb_frame; current->total_frames = nb_frame; - memset(current->frame_table, 0, nb_frame * 4); + memset(current->frame_table, 0, + nb_frame * sizeof(*current->frame_table)); uint32_t i = 1; for (; i < CEIL(nb_frame, PAGE_SIZE); i++)