[vlc-commits] bluray: protection against incorrect paths

Hugo Beauzée-Luyssen git at videolan.org
Thu Mar 8 12:25:36 CET 2012


vlc | branch: master | Hugo Beauzée-Luyssen <beauze.h at gmail.com> | Thu Mar  8 12:13:37 2012 +0100| [11e721fa2da7eaf8a0088afc9e2caeedaa59af56] | committer: Jean-Baptiste Kempf

bluray: protection against incorrect paths

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

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

 modules/access/bluray.c |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/modules/access/bluray.c b/modules/access/bluray.c
index c201b58..ede3960 100644
--- a/modules/access/bluray.c
+++ b/modules/access/bluray.c
@@ -200,6 +200,13 @@ static int blurayOpen( vlc_object_t *object )
 
     /* Warning the user about AACS/BD+ */
     const BLURAY_DISC_INFO *disc_info = bd_get_disc_info(p_sys->bluray);
+
+    /* Is it a bluray? */
+    if (!disc_info->bluray_detected) {
+        error_msg = "Path doesn't appear to be a bluray";
+        goto error;
+    }
+
     msg_Info(p_demux, "First play: %i, Top menu: %i\n"
                       "HDMV Titles: %i, BD-J Titles: %i, Other: %i",
              disc_info->first_play_supported, disc_info->top_menu_supported,



More information about the vlc-commits mailing list