[Piglit] [PATCH] arb_program_interface_query: Silence uninitialized variable warning.
Vinson Lee
vlee at freedesktop.org
Mon Nov 30 21:50:35 PST 2015
Fixes Coverity "uninitialized scalar variable" defect.
Signed-off-by: Vinson Lee <vlee at freedesktop.org>
---
tests/spec/arb_program_interface_query/getprogramresourceiv.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/tests/spec/arb_program_interface_query/getprogramresourceiv.c b/tests/spec/arb_program_interface_query/getprogramresourceiv.c
index 769e29f..7ef72cc 100755
--- a/tests/spec/arb_program_interface_query/getprogramresourceiv.c
+++ b/tests/spec/arb_program_interface_query/getprogramresourceiv.c
@@ -668,6 +668,9 @@ check_prop(GLuint prog, GLenum programInterface, int index, const char *name,
case GL_BUFFER_VARIABLE:
pif = GL_SHADER_STORAGE_BLOCK;
break;
+ default:
+ assert(0);
+ pif = GL_NONE;
}
parent_idx = glGetProgramResourceIndex(prog, pif,
@@ -739,6 +742,9 @@ check_prop(GLuint prog, GLenum programInterface, int index, const char *name,
case GL_COMPUTE_SUBROUTINE_UNIFORM:
pif = GL_COMPUTE_SUBROUTINE;
break;
+ default:
+ assert(0);
+ pif = GL_NONE;
}
/* check that the return count is as expected */
--
2.6.3
More information about the Piglit
mailing list