glslstage: initialize output params to 0 before calling gl functions
authorJulien Isorce <j.isorce@samsung.com>
Wed, 28 Oct 2015 14:41:54 +0000 (14:41 +0000)
committerJulien Isorce <j.isorce@samsung.com>
Wed, 28 Oct 2015 14:41:54 +0000 (14:41 +0000)
The client side API of the Chromium's GPU Process has asserts
in debug mode that check that output params are initialized to 0.

gst-libs/gst/gl/gstglslstage.c

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