glslstage: initialize output params to 0 before calling gl functions

The client side API of the Chromium's GPU Process has asserts
in debug mode that check that output params are initialized to 0.
This commit is contained in:
Julien Isorce 2015-10-28 14:41:54 +00:00 committed by Tim-Philipp Müller
parent 68215b0a47
commit 6bb560a4eb

View file

@ -471,8 +471,10 @@ _compile_shader (GstGLContext * context, struct compile *data)
gl->CompileShader (priv->handle); gl->CompileShader (priv->handle);
/* FIXME: supported threaded GLSL compilers and don't destroy compilation /* FIXME: supported threaded GLSL compilers and don't destroy compilation
* performance by getting the compilation result directly after compilation */ * performance by getting the compilation result directly after compilation */
status = GL_FALSE;
gl->GetShaderiv (priv->handle, GL_COMPILE_STATUS, &status); gl->GetShaderiv (priv->handle, GL_COMPILE_STATUS, &status);
len = 0;
vtable->GetShaderInfoLog (priv->handle, sizeof (info_buffer) - 1, &len, vtable->GetShaderInfoLog (priv->handle, sizeof (info_buffer) - 1, &len,
info_buffer); info_buffer);
info_buffer[len] = '\0'; info_buffer[len] = '\0';