mirror of https://github.com/mpv-player/mpv
osx: add NULL check for input context in a missing case
Fixes a crash on exit under certain circumstances.
This commit is contained in:
parent
ebc5237c36
commit
ed805e16fc
|
@ -247,7 +247,8 @@ void cocoa_set_input_context(struct input_ctx *input_context)
|
||||||
- (void)wakeup
|
- (void)wakeup
|
||||||
{
|
{
|
||||||
[_input_lock lock];
|
[_input_lock lock];
|
||||||
mp_input_wakeup(_inputContext);
|
if (_inputContext)
|
||||||
|
mp_input_wakeup(_inputContext);
|
||||||
[_input_lock unlock];
|
[_input_lock unlock];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue