[vlc-commits] macosx: fixed race condition crash when closing the vout
Felix Paul Kühne
git at videolan.org
Thu Dec 6 00:55:03 CET 2012
vlc/vlc-2.0 | branch: master | Felix Paul Kühne <fkuehne at videolan.org> | Thu Dec 6 10:26:30 2012 +1100| [113cbbcda68316362273f5b85db1f91ee964483e] | committer: Felix Paul Kühne
macosx: fixed race condition crash when closing the vout
vout_display_opengl_Delete will call OpenglLock, so it is a bad idea to previously release sys->glView
(cherry picked from commit c6a264bf022d834e7617948e4923012fc1d8369d)
> http://git.videolan.org/gitweb.cgi/vlc/vlc-2.0.git/?a=commit;h=113cbbcda68316362273f5b85db1f91ee964483e
---
modules/video_output/macosx.m | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/modules/video_output/macosx.m b/modules/video_output/macosx.m
index 7bd43fe..c25112a 100644
--- a/modules/video_output/macosx.m
+++ b/modules/video_output/macosx.m
@@ -266,11 +266,11 @@ void Close (vlc_object_t *this)
[(id)sys->container performSelectorOnMainThread:@selector(release) withObject:nil waitUntilDone:NO];
[sys->glView performSelectorOnMainThread:@selector(removeFromSuperview) withObject:nil waitUntilDone:NO];
- [sys->glView release];
-
if (sys->gl.sys != NULL)
vout_display_opengl_Delete (sys->vgl);
+ [sys->glView release];
+
if (sys->embed)
vout_display_DeleteWindow (vd, sys->embed);
free (sys);
More information about the vlc-commits
mailing list