From d77718d4223e218b9b3b7eee64b9628cd37c6b80 Mon Sep 17 00:00:00 2001 From: "alexey.lysiuk" Date: Thu, 5 Jan 2017 15:47:16 +0200 Subject: [PATCH] Fixed harmless uninitialized variables warnings No more 'variable is used uninitialized whenever switch default is taken' warnings reported by GCC/Clang --- src/gl/renderer/gl_renderbuffers.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gl/renderer/gl_renderbuffers.cpp b/src/gl/renderer/gl_renderbuffers.cpp index 77e77bf5b..fad79767c 100644 --- a/src/gl/renderer/gl_renderbuffers.cpp +++ b/src/gl/renderer/gl_renderbuffers.cpp @@ -482,7 +482,7 @@ GLuint FGLRenderBuffers::Create2DTexture(const FString &name, GLuint format, int glBindTexture(GL_TEXTURE_2D, handle); FGLDebug::LabelObject(GL_TEXTURE, handle, name); - GLenum dataformat, datatype; + GLenum dataformat = 0, datatype = 0; switch (format) { case GL_RGBA8: dataformat = GL_RGBA; datatype = GL_UNSIGNED_BYTE; break;