Some vouts like macosx and glwin32 do not use vlc_gl_Create to create a
vlc_gl_t, and set no module but vlc_gl_Destroy expects that a module is
set and will therefore fail for these vouts.
This commit replaces vlc_gl_Destroy in these vouts with direct calls to
vlc_object_release.
Signed-off-by: Thomas Guillem <thomas@gllm.fr>
- vlc_gl_Destroy(sys->gl);
+ vlc_object_release(sys->gl);
if (sys->glContext)
CGLReleaseContext(sys->glContext);
if (sys->glContext)
CGLReleaseContext(sys->glContext);
vout_display_opengl_Delete (sys->vgl);
if (sys->gl != NULL)
vout_display_opengl_Delete (sys->vgl);
if (sys->gl != NULL)
- vlc_gl_Destroy (sys->gl);
+ vlc_object_release(sys->gl);
vout_display_opengl_Delete(sys->vgl);
if (sys->gl)
vout_display_opengl_Delete(sys->vgl);
if (sys->gl)
- vlc_gl_Destroy(sys->gl);
+ vlc_object_release(sys->gl);
if (sys->hGLDC && sys->hGLRC)
wglMakeCurrent(NULL, NULL);
if (sys->hGLDC && sys->hGLRC)
wglMakeCurrent(NULL, NULL);