Package: vobcopy
Version: 1.1.0-1
Severity: normal
Tags: patch

Around line 1736 in vobcopy.c the return of DVDReadBlocks is not checked.  If 
an error occurs the the -1 return is
passed unchecked to write, which fails.  A confusing error message is displayed.


-- System Information:
Debian Release: lenny/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (1, 'experimental')
Architecture: i386 (i686)

Kernel: Linux 2.6.24.3 (SMP w/1 CPU core)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

Versions of packages vobcopy depends on:
ii  libc6                         2.7-9      GNU C Library: Shared libraries
ii  libdvdread3                   0.9.7-8    library for reading DVDs

vobcopy recommends no packages.

-- no debconf information
Only in vobcopy-1.1.0: dvd.o
Only in vobcopy-1.1.0: MNT0EFM116-1.vob.partial
Only in vobcopy-1.1.0: vobcopy
diff -ur vobcopy-1.1.0.orig/vobcopy.c vobcopy-1.1.0/vobcopy.c
--- vobcopy-1.1.0.orig/vobcopy.c        2008-01-05 00:37:21.000000000 +0100
+++ vobcopy-1.1.0/vobcopy.c     2008-03-15 15:16:54.000000000 +0100
@@ -1736,6 +1736,12 @@
             }
 
           blocks = DVDReadBlocks( dvd_file,( offset + seek_start ), 
file_block_count, bufferin );
+         if (blocks < 0)
+           {
+             fprintf (stderr, "\n[Error] DVD read error %s\n", 
+                       strerror (errno));
+             exit (1);
+           }
           if( write( streamout, bufferin, DVD_VIDEO_LB_LEN * blocks ) < 0 )
             {
               fprintf( stderr, "\n[Error] Write() error\n"

Reply via email to