mirror of https://github.com/mpv-player/mpv
I experienced several segfaults when trying to play (unencrypted) DVDs
from harddisk using xine/ogle/mplayer with the respective libdvdnav support feature. I found that while libdvdnav itself may do something wrong by trying to read beyond the end of the files, it was actually the fault of libdvdread that a segfault resulted. The following tiny patch fixes the problem and it seems that libdvdnav can very well live with the "short read" result it gets then - navigation worked fine after applying the patch: patch by Peter Niemayer <niemayer@isg.de> & H}kan Hjort <d95hjort@dtek.chalmers.se> git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@7359 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
47902f3c88
commit
f9963b5442
|
@ -815,7 +815,10 @@ static int DVDReadBlocksPath( dvd_file_t *dvd_file, unsigned int offset,
|
|||
if( ret < 0 ) return ret;
|
||||
/* FIXME: This is wrong if i is the last file in the set.
|
||||
* also error from this read will not show in ret. */
|
||||
|
||||
|
||||
/* Does the next part exist? If not then return now. */
|
||||
if( !dvd_file->title_devs[ i + 1 ] ) return ret;
|
||||
|
||||
/* Read part 2 */
|
||||
off = DVDinput_seek( dvd_file->title_devs[ i + 1 ],
|
||||
0, DVDINPUT_NOFLAGS );
|
||||
|
|
Loading…
Reference in New Issue