changeset 430:43c9bfd418d1 src

Make sure program_map is not NULL. pgc->program_map should be checked before dereferencing. On the DVD "Jack Reacher" this was discovered as a problem. Bug discovery and suggested fix given by Cathy McDonald. Thanks! Patch by Erik Hovland !erik#hovland$org%
author rathann
date Thu, 03 Oct 2013 23:02:55 +0000
parents 2e6f41e04ca1
children fef53ca48541
files searching.c
diffstat 1 files changed, 4 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/searching.c	Thu Oct 03 22:43:52 2013 +0000
+++ b/searching.c	Thu Oct 03 23:02:55 2013 +0000
@@ -625,6 +625,10 @@
       printerr("PGC missing.");
       continue;
     }
+    if (pgc->program_map == NULL) {
+      printerr("Program map missing.");
+      continue;
+    }
     if(ptt[i].pgn > pgc->nr_of_programs) {
       printerr("WRONG part number.");
       goto fail;