Commit 803dd959 authored by Daniel Baumann's avatar Daniel Baumann Committed by Reinhard Tartler

Imported Debian patch 0.9.7-8

parent bdafcaff
libdvdread (0.9.7-8) unstable; urgency=low
* Applied change from Bastian Blank <waldi@debian.org> to improve udf patch.
-- Daniel Baumann <daniel@debian.org> Fri, 22 Feb 2008 20:32:00 +0100
libdvdread (0.9.7-7) unstable; urgency=low
* Applied change from Petr Salinger <Petr.Salinger@seznam.cz> to update
......
......@@ -9,8 +9,8 @@
diff -Naurp libdvdread-0.9.7.orig/dvdread/dvd_reader.c libdvdread-0.9.7/dvdread/dvd_reader.c
--- libdvdread-0.9.7.orig/dvdread/dvd_reader.c 2006-10-06 07:58:03.000000000 +0000
+++ libdvdread-0.9.7/dvdread/dvd_reader.c 2008-01-12 14:09:28.000000000 +0000
@@ -1393,6 +1393,24 @@ int DVDFileSeek( dvd_file_t *dvd_file, i
+++ libdvdread-0.9.7/dvdread/dvd_reader.c 2008-02-22 19:42:47.000000000 +0000
@@ -1393,6 +1393,28 @@ int DVDFileSeek( dvd_file_t *dvd_file, i
return offset;
}
......@@ -20,9 +20,13 @@ diff -Naurp libdvdread-0.9.7.orig/dvdread/dvd_reader.c libdvdread-0.9.7/dvdread/
+ if( dvd_file == NULL || offset < 0 )
+ return -1;
+
+ if( dvd_file->filesize < force_size) {
+ dvd_file->filesize = force_size;
+ fprintf(stderr, "libdvdread: Ignored UDF provided size of file.\n");
+ if( dvd_file->dvd->isImageFile ) {
+ if( force_size < 0 )
+ force_size = (offset - 1) / DVD_VIDEO_LB_LEN + 1;
+ if( dvd_file->filesize < force_size ) {
+ dvd_file->filesize = force_size;
+ fprintf(stderr, "libdvdread: Ignored UDF provided size of file.\n");
+ }
+ }
+
+ if( offset > dvd_file->filesize * DVD_VIDEO_LB_LEN ) {
......@@ -35,9 +39,18 @@ diff -Naurp libdvdread-0.9.7.orig/dvdread/dvd_reader.c libdvdread-0.9.7/dvdread/
#ifndef HAVE_UINTPTR_T
#warning "Assuming that (unsigned long) can hold (void *)"
typedef unsigned long uintptr_t;
@@ -1444,7 +1466,7 @@ ssize_t DVDReadBytes( dvd_file_t *dvd_fi
memcpy( data, &(secbuf[ seek_byte ]), byte_size );
free( secbuf_start );
- dvd_file->seek_pos += byte_size;
+ DVDFileSeekForce(dvd_file, dvd_file->seek_pos + byte_size, -1);
return byte_size;
}
diff -Naurp libdvdread-0.9.7.orig/dvdread/dvd_reader.h libdvdread-0.9.7/dvdread/dvd_reader.h
--- libdvdread-0.9.7.orig/dvdread/dvd_reader.h 2006-10-06 08:12:31.000000000 +0000
+++ libdvdread-0.9.7/dvdread/dvd_reader.h 2008-01-12 14:09:28.000000000 +0000
+++ libdvdread-0.9.7/dvdread/dvd_reader.h 2008-02-22 19:42:28.000000000 +0000
@@ -240,6 +240,8 @@ ssize_t DVDReadBlocks( dvd_file_t *, int
*/
int DVDFileSeek( dvd_file_t *, int );
......@@ -49,7 +62,7 @@ diff -Naurp libdvdread-0.9.7.orig/dvdread/dvd_reader.h libdvdread-0.9.7/dvdread/
* on the information files, and may not be used for reading from a VOB. This
diff -Naurp libdvdread-0.9.7.orig/dvdread/ifo_read.c libdvdread-0.9.7/dvdread/ifo_read.c
--- libdvdread-0.9.7.orig/dvdread/ifo_read.c 2006-01-22 12:19:19.000000000 +0000
+++ libdvdread-0.9.7/dvdread/ifo_read.c 2008-01-12 14:09:28.000000000 +0000
+++ libdvdread-0.9.7/dvdread/ifo_read.c 2008-02-22 19:42:28.000000000 +0000
@@ -106,6 +106,10 @@ static inline int DVDFileSeek_( dvd_file
return (DVDFileSeek(dvd_file, (int)offset) == (int)offset);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment