Commit 27aaf3d5 authored by Chen Bill's avatar Chen Bill Committed by GitHub

fix dereference nullptr & use uninitialized memory (#5)

* SColor: initialize color

* r5684 on ogl-es
parent 0515d19c
......@@ -444,7 +444,7 @@ namespace video
}
//! color in A8R8G8B8 Format
u32 color;
u32 color{};
};
......
......@@ -71,10 +71,13 @@ namespace video
//! Destructor
~SMaterialLayer()
{
if(TextureMatrix)
{
MatrixAllocator.destruct(TextureMatrix);
MatrixAllocator.deallocate(TextureMatrix);
}
}
//! Assignment operator
/** \param other Material layer to copy from.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment