[libdvdnav-devel] Fix crashes with some DVDs on describe_title

Jean-Baptiste Kempf git at videolan.org
Tue Sep 1 16:01:46 CEST 2015


libdvdnav | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Tue Sep  1 16:00:59 2015 +0200| [d88c77fa205efe880d922b1dd414eaa6d678751d] | committer: Jean-Baptiste Kempf

Fix crashes with some DVDs on describe_title

This is a stop-over, but the actual issue is not fixed

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

 src/searching.c |    5 +++++
 1 file changed, 5 insertions(+)

diff --git a/src/searching.c b/src/searching.c
index 70c0f85..4f422d6 100644
--- a/src/searching.c
+++ b/src/searching.c
@@ -647,6 +647,11 @@ uint32_t dvdnav_describe_title_chapters(dvdnav_t *this, int32_t title, uint64_t
   length = 0;
   for(i=0; i<parts; i++) {
     uint32_t cellnr, endcellnr;
+    if (ptt[i] == NULL) {
+      printerr("ptt NULL: %i %i.", i, parts );
+      continue;
+    }
+
     if (ptt[i].pgcn == 0 || ptt[i].pgcn > ifo->vts_pgcit->nr_of_pgci_srp) {
       printerr("PGCN out of bounds.");
       continue;



More information about the libdvdnav-devel mailing list