Re: libdvdread has trouble with some DVD images

H}kan Hjort <[email protected]>
Newsgroups gmane.comp.video.ogle.devel
Message-ID <[email protected]>
Wed Jul 24 2002, Jeff Bowden wrote:
> Continuing my investigation, I commented out the offending assert and 
> got to another one:
> 
> tccat: ifo_read.c:831: ifoRead_TT_SRPT: Assertion 
> `(int)tt_srpt->nr_of_srpts * sizeof(title_info_t) <= info_length' failed.
> 
> After adding some fprintf's I found that:
>    tt_srpt->nr_of_srpts = 3
>    sizeof(title_info_t) = 12
>    info_length = 24
> 
so we have 3 Title Tracks. each one is 12 bytes long
But the 'lenght' is only big enough for two title tracks...
Could you find out if it only has two Title tracks or if it really
should be three.

> If I comment out that assert I get a segfault.  I tried the following 
> modification but it still segfaults:
> 
>  if ((int)tt_srpt->nr_of_srpts * sizeof(title_info_t) > info_length)
>      tt_srpt->nr_of_srpts = info_length / sizeof(title_info_t);
> 
Looks like a good idea.  Might be that it uses 3-1 to index that array
without checking, some other place.

-- 
Håkan Hjort
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.