fix(test): zero-initialize state structs to avoid stack corruption
This commit is contained in:
@@ -150,7 +150,7 @@ TEST_F(OpenGLTestFixture, CommandList_SetPrimitiveTopology) {
|
||||
TEST_F(OpenGLTestFixture, CommandList_SetDepthStencilState) {
|
||||
OpenGLCommandList cmdList;
|
||||
|
||||
DepthStencilState state;
|
||||
DepthStencilState state = {};
|
||||
state.depthEnable = true;
|
||||
state.depthWriteMask = true;
|
||||
state.depthFunc = ComparisonFunc::Less;
|
||||
@@ -165,7 +165,7 @@ TEST_F(OpenGLTestFixture, CommandList_SetDepthStencilState) {
|
||||
TEST_F(OpenGLTestFixture, CommandList_SetBlendState) {
|
||||
OpenGLCommandList cmdList;
|
||||
|
||||
BlendState state;
|
||||
BlendState state = {};
|
||||
state.renderTargets[0].blendEnable = true;
|
||||
state.renderTargets[0].srcBlend = BlendFactor::SrcAlpha;
|
||||
state.renderTargets[0].dstBlend = BlendFactor::InvSrcAlpha;
|
||||
|
||||
Reference in New Issue
Block a user