Check Display class in InitFont()

This commit is contained in:
EnderIce2 2024-03-19 02:20:58 +02:00
parent 9722a44dc2
commit 464022a61d
Signed by untrusted user who does not match committer: enderice2
GPG Key ID: EACC3AD603BAB4DD

View File

@ -105,6 +105,12 @@ nsa void InitFont()
{
/* Hope we won't crash here */
if (Display == nullptr)
{
error("Can't initialize font without display initalized");
CPU::Stop();
}
if (FbBeforePanic != nullptr)
KernelAllocator.FreePages(FbBeforePanic, FbPagesBeforePanic);
else