mirror of
https://github.com/EnderIce2/Fennix.git
synced 2025-07-06 12:59:15 +00:00
Prevent dangling pointer
This commit is contained in:
@ -15,7 +15,8 @@ namespace GraphicalUserInterface
|
||||
{
|
||||
// TODO: Optimize this
|
||||
this->mem->FreePages(this->Buffer->Data, TO_PAGES(this->Buffer->Size));
|
||||
delete this->Buffer;
|
||||
this->Buffer->Data = nullptr;
|
||||
delete this->Buffer, this->Buffer = nullptr;
|
||||
|
||||
this->Buffer = new ScreenBitmap;
|
||||
this->Buffer->Width = e->Resize.Width;
|
||||
|
Reference in New Issue
Block a user