Commit ab21bfce authored by Clément Stenac's avatar Clément Stenac

Fix refcount bug

parent 11bfb464
...@@ -272,8 +272,8 @@ int IntfAutoMenuBuilder( intf_thread_t *p_intf, ...@@ -272,8 +272,8 @@ int IntfAutoMenuBuilder( intf_thread_t *p_intf,
void VideoPopupMenu( intf_thread_t *p_intf, wxWindow *p_parent, void VideoPopupMenu( intf_thread_t *p_intf, wxWindow *p_parent,
const wxPoint& pos ) const wxPoint& pos )
{ {
POPUP_BOILERPLATE; POPUP_BOILERPLATE;
if( p_input ) if( p_input )
{ {
vlc_object_yield( p_input ); vlc_object_yield( p_input );
as_varnames.push_back( "video-es" ); as_varnames.push_back( "video-es" );
...@@ -289,6 +289,7 @@ void VideoPopupMenu( intf_thread_t *p_intf, wxWindow *p_parent, ...@@ -289,6 +289,7 @@ void VideoPopupMenu( intf_thread_t *p_intf, wxWindow *p_parent,
} }
vlc_object_release( p_input ); vlc_object_release( p_input );
} }
vlc_object_release( p_playlist );
CREATE_POPUP; CREATE_POPUP;
} }
...@@ -310,6 +311,7 @@ void AudioPopupMenu( intf_thread_t *p_intf, wxWindow *p_parent, ...@@ -310,6 +311,7 @@ void AudioPopupMenu( intf_thread_t *p_intf, wxWindow *p_parent,
} }
vlc_object_release( p_input ); vlc_object_release( p_input );
} }
vlc_object_release( p_playlist );
CREATE_POPUP; CREATE_POPUP;
} }
...@@ -338,6 +340,7 @@ void MiscPopupMenu( intf_thread_t *p_intf, wxWindow *p_parent, ...@@ -338,6 +340,7 @@ void MiscPopupMenu( intf_thread_t *p_intf, wxWindow *p_parent,
p_intf->p_sys->p_popup_menu = &popupmenu; p_intf->p_sys->p_popup_menu = &popupmenu;
p_parent->PopupMenu( &popupmenu, pos.x, pos.y ); p_parent->PopupMenu( &popupmenu, pos.x, pos.y );
p_intf->p_sys->p_popup_menu = NULL; p_intf->p_sys->p_popup_menu = NULL;
vlc_object_release( p_playlist );
} }
void PopupMenu( intf_thread_t *p_intf, wxWindow *p_parent, void PopupMenu( intf_thread_t *p_intf, wxWindow *p_parent,
...@@ -393,6 +396,7 @@ void PopupMenu( intf_thread_t *p_intf, wxWindow *p_parent, ...@@ -393,6 +396,7 @@ void PopupMenu( intf_thread_t *p_intf, wxWindow *p_parent,
p_intf->p_sys->p_popup_menu = &popupmenu; p_intf->p_sys->p_popup_menu = &popupmenu;
p_parent->PopupMenu( &popupmenu, pos.x, pos.y ); p_parent->PopupMenu( &popupmenu, pos.x, pos.y );
p_intf->p_sys->p_popup_menu = NULL; p_intf->p_sys->p_popup_menu = NULL;
vlc_object_release( p_playlist );
} }
/***************************************************************************** /*****************************************************************************
......
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