[vlc-commits] input/var: fix deletion of title navigation callbacks
Filip Roséen
git at videolan.org
Mon Jul 18 06:24:30 CEST 2016
vlc | branch: master | Filip Roséen <filip at videolabs.io> | Sat Jul 16 22:38:26 2016 +0200| [3f66ca77df6e712852e920230612021c68565df4] | committer: Jean-Baptiste Kempf
input/var: fix deletion of title navigation callbacks
Just as it does not make sense to add callbacks for {next,prev}-title
and menu-{popup,title} if we do not have more than one title, it does
not make sense to delete such callbacks under the same condition
(especially since we would delete in cases we do not create).
Close #17021
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=3f66ca77df6e712852e920230612021c68565df4
---
src/input/var.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/src/input/var.c b/src/input/var.c
index eb64cc7..9423996 100644
--- a/src/input/var.c
+++ b/src/input/var.c
@@ -230,9 +230,11 @@ void input_ControlVarStop( input_thread_t *p_input )
if( !p_input->b_preparsing )
InputDelCallbacks( p_input, p_input_callbacks );
+ if( p_input->p->i_title > 1 )
+ InputDelCallbacks( p_input, p_input_title_navigation_callbacks );
+
if( p_input->p->i_title > 0 )
{
- InputDelCallbacks( p_input, p_input_title_navigation_callbacks );
InputDelCallbacks( p_input, p_input_seekpoint_navigation_callbacks );
for( int i = 0; i < p_input->p->i_title; i++ )
More information about the vlc-commits
mailing list