From 23dae72bceecfea7640a5bef7515164b3c806515 Mon Sep 17 00:00:00 2001 From: aliaspider Date: Thu, 22 Mar 2018 22:25:04 +0100 Subject: [PATCH] prevent reads of uninitialized memory. --- GPU/Common/FramebufferCommon.h | 4 ++-- GPU/GPUCommon.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/GPU/Common/FramebufferCommon.h b/GPU/Common/FramebufferCommon.h index b6febf7fa3..8e8ffc4f8c 100644 --- a/GPU/Common/FramebufferCommon.h +++ b/GPU/Common/FramebufferCommon.h @@ -387,8 +387,8 @@ protected: bool gameUsesSequentialCopies_ = false; // Sampled in BeginFrame for safety. - float renderWidth_; - float renderHeight_; + float renderWidth_ = 0.0f; + float renderHeight_ = 0.0f; int pixelWidth_; int pixelHeight_; int bloomHack_ = 0; diff --git a/GPU/GPUCommon.h b/GPU/GPUCommon.h index afd0add47b..44bb9ab6d2 100644 --- a/GPU/GPUCommon.h +++ b/GPU/GPUCommon.h @@ -332,8 +332,8 @@ protected: bool debugRecording_; bool interruptsEnabled_; bool resized_; - DrawType lastDraw_; - GEPrimitiveType lastPrim_; + DrawType lastDraw_ = DRAW_UNKNOWN; + GEPrimitiveType lastPrim_ = GE_PRIM_INVALID; int vertexCost_ = 0;