Just a check

This commit is contained in:
2024-03-23 00:15:49 +01:00
parent 5964980955
commit 35fb5c4200

View File

@@ -79,6 +79,7 @@ void parse_limine_memmap(struct limine_memmap_entry *entries, unsigned int num,
if (entry->type != what_is_considered_free) continue;
uint64_t roundbase = roundup4k(entry->base);
if (roundbase >= (entry->base + entry->length)) continue;
if (entry->length <= (roundbase - entry->base)) continue;
uint64_t len = rounddown4k(entry->length - (roundbase - entry->base));
if (len == 0) continue;