1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-16 19:35:08 +00:00

UserspaceEmulator: Make sure ELF data segments are zero-initialized

(And all other memory, too.) This will mutate later when we add shadow
memory etc, but for now just zero-initialize it since that's expected
by the emulated program.
This commit is contained in:
Andreas Kling 2020-07-12 00:27:25 +02:00
parent 7f394435da
commit ce51cf90c6

View file

@ -42,7 +42,7 @@ public:
SimpleRegion(u32 base, u32 size)
: Region(base, size)
{
m_data = (u8*)malloc(size);
m_data = (u8*)calloc(1, size);
}
~SimpleRegion()