Commit b3b6658b authored by Pierre d'Herbemont's avatar Pierre d'Herbemont

minimal_macosx: Don't attempt to use the vout when there is none.

parent 924d4ff8
...@@ -360,6 +360,8 @@ void cocoaglvoutviewUnlock( vout_thread_t * p_vout ) ...@@ -360,6 +360,8 @@ void cocoaglvoutviewUnlock( vout_thread_t * p_vout )
- (void) update - (void) update
{ {
if (!p_vout)
return;
if( kCGLNoError != CGLLockContext([[self openGLContext] CGLContextObj]) ) if( kCGLNoError != CGLLockContext([[self openGLContext] CGLContextObj]) )
return; return;
[super update]; [super update];
...@@ -368,6 +370,8 @@ void cocoaglvoutviewUnlock( vout_thread_t * p_vout ) ...@@ -368,6 +370,8 @@ void cocoaglvoutviewUnlock( vout_thread_t * p_vout )
- (void) drawRect: (NSRect) rect - (void) drawRect: (NSRect) rect
{ {
if (!p_vout)
return;
if( kCGLNoError != CGLLockContext([[self openGLContext] CGLContextObj]) ) if( kCGLNoError != CGLLockContext([[self openGLContext] CGLContextObj]) )
return; return;
[[self openGLContext] flushBuffer]; [[self openGLContext] flushBuffer];
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment