[vlc-devel] [PATCH] bluray: fix current chapter

Petri Hintukainen phintuka at gmail.com
Wed Nov 18 08:59:25 CET 2015


---
 modules/access/bluray.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/modules/access/bluray.c b/modules/access/bluray.c
index f9fc56f..60da219 100644
--- a/modules/access/bluray.c
+++ b/modules/access/bluray.c
@@ -1944,8 +1944,11 @@ static void blurayHandleEvent(demux_t *p_demux, const BD_EVENT *e)
         blurayUpdateCurrentClip(p_demux, e->param);
         break;
     case BD_EVENT_CHAPTER:
+        if (e->param && e->param < 0xffff)
+          p_demux->info.i_seekpoint = e->param - 1;
+        else
+          p_demux->info.i_seekpoint = 0;
         p_demux->info.i_update |= INPUT_UPDATE_SEEKPOINT;
-        p_demux->info.i_seekpoint = e->param;
         break;
     case BD_EVENT_ANGLE:
         break;
-- 
2.5.0



More information about the vlc-devel mailing list