summaryrefslogtreecommitdiff
path: root/tests/fbo
diff options
context:
space:
mode:
authorVinson Lee <vlee@freedesktop.org>2013-12-24 15:57:45 -0800
committerChad Versace <chad.versace@linux.intel.com>2013-12-26 14:10:18 -0800
commit3cebb8e4da6ad5f6499886b3e5a64bbebd17130a (patch)
treee3c00698763e1a6e6228a36dfb2dded92423c5e5 /tests/fbo
parentb170bb98e53c0f5c718090efc8efa5a0513db349 (diff)
fbo-generatemipmap-formats: Fix uninitialized variable warnings.
Fix GCC maybe-uninitialized warnings. fbo-generatemipmap-formats.c: In function 'test_format': fbo-generatemipmap-formats.c:112:15: warning: 'format' may be used uninitialized in this function [-Wmaybe-uninitialized] glTexImage2D(GL_TEXTURE_2D, i, internalformat, ^ fbo-generatemipmap-formats.c:80:15: note: 'format' was declared here GLenum type, format; ^ fbo-generatemipmap-formats.c:112:15: warning: 'type' may be used uninitialized in this function [-Wmaybe-uninitialized] glTexImage2D(GL_TEXTURE_2D, i, internalformat, ^ fbo-generatemipmap-formats.c:80:9: note: 'type' was declared here GLenum type, format; ^ Signed-off-by: Vinson Lee <vlee@freedesktop.org> Reviewed-by: Chad Versace <chad.versace@linux.intel.com>
Diffstat (limited to 'tests/fbo')
-rw-r--r--tests/fbo/fbo-generatemipmap-formats.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/fbo/fbo-generatemipmap-formats.c b/tests/fbo/fbo-generatemipmap-formats.c
index d0a738c8c..666030fd4 100644
--- a/tests/fbo/fbo-generatemipmap-formats.c
+++ b/tests/fbo/fbo-generatemipmap-formats.c
@@ -94,6 +94,8 @@ create_tex(GLenum internalformat, GLenum baseformat, GLenum basetype)
type = GL_FLOAT;
} else {
assert(0);
+ format = GL_NONE;
+ type = GL_NONE;
}
} else {
tex = piglit_rgbw_texture(internalformat,