glcontext: correct precondition for get_gl_version

The intention was to assert if both maj and min were NULL (as there would be no
point calling the function).  Instead if either maj or min were NULL, the assert
would occur.

Fix that.
This commit is contained in:
Matthew Waters 2016-06-28 13:02:32 +10:00 committed by Tim-Philipp Müller
parent f457e29192
commit db51c90d5d

View file

@ -1513,7 +1513,7 @@ void
gst_gl_context_get_gl_version (GstGLContext * context, gint * maj, gint * min) gst_gl_context_get_gl_version (GstGLContext * context, gint * maj, gint * min)
{ {
g_return_if_fail (GST_IS_GL_CONTEXT (context)); g_return_if_fail (GST_IS_GL_CONTEXT (context));
g_return_if_fail (maj != NULL && min != NULL); g_return_if_fail (!(maj == NULL && min == NULL));
if (maj) if (maj)
*maj = context->priv->gl_major; *maj = context->priv->gl_major;