[vlc-commits] bluray: fix abort() when empty overlay is closed

Petri Hintukainen git at videolan.org
Thu Feb 13 12:59:19 CET 2014


vlc | branch: master | Petri Hintukainen <phintuka at users.sourceforge.net> | Wed Feb 12 22:37:49 2014 +0200| [e4dabd8c95c03513012eac0e56baeb23acf4bf4b] | committer: Jean-Baptiste Kempf

bluray: fix abort() when empty overlay is closed

HDMV titles can construct empty overlay with invisible buttons to enable navigation.
This is used in ex. photo galleries (to flip image) and with audio navigation ("spoken menu").

Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=e4dabd8c95c03513012eac0e56baeb23acf4bf4b
---

 modules/access/bluray.c |   10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/modules/access/bluray.c b/modules/access/bluray.c
index bc4c8e9..1d34060 100644
--- a/modules/access/bluray.c
+++ b/modules/access/bluray.c
@@ -791,10 +791,12 @@ static void blurayCloseOverlay(demux_t *p_demux, int plane)
             return;
 
     /* All overlays have been closed */
-    var_DelCallback(p_sys->p_vout, "mouse-moved", onMouseEvent, p_demux);
-    var_DelCallback(p_sys->p_vout, "mouse-clicked", onMouseEvent, p_demux);
-    vlc_object_release(p_sys->p_vout);
-    p_sys->p_vout = NULL;
+    if (p_sys->p_vout != NULL) {
+        var_DelCallback(p_sys->p_vout, "mouse-moved", onMouseEvent, p_demux);
+        var_DelCallback(p_sys->p_vout, "mouse-clicked", onMouseEvent, p_demux);
+        vlc_object_release(p_sys->p_vout);
+        p_sys->p_vout = NULL;
+    }
 }
 
 /*



More information about the vlc-commits mailing list