Commit f2f58c1b authored by David Fuhrmann's avatar David Fuhrmann

macosx: correctly unregister input-current callback

Fixes a crash when quitting the interface during media playback.
parent eaa1ca1c
......@@ -166,7 +166,7 @@ static int InputEvent(vlc_object_t *p_this, const char *psz_var,
- (void)dealloc
{
intf_thread_t *p_intf = VLCIntf;
msg_Dbg(VLCIntf, "Deinitializing input manager");
if (p_current_input) {
/* continue playback where you left off */
[[o_main playlist] storePlaybackPositionForItem:p_current_input];
......@@ -176,8 +176,7 @@ static int InputEvent(vlc_object_t *p_this, const char *psz_var,
p_current_input = NULL;
}
if (p_intf)
var_DelCallback(p_intf, "input-current", InputThreadChanged, (__bridge void *)self);
var_DelCallback(pl_Get(VLCIntf), "input-current", InputThreadChanged, (__bridge void *)self);
dispatch_release(informInputChangedQueue);
}
......
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