[libdvdnav-devel] src/dvd_reader.c: Fix a couple of fprintf format strings

Andrew Clayton git at videolan.org
Fri Oct 24 16:29:23 CEST 2014


libdvdread | branch: master | Andrew Clayton <andrew at digital-domain.net> | Fri Oct 24 15:21:30 2014 +0100| [5cdc819bedc1b050c81d81c3b063d37fe54080b8] | committer: Jean-Baptiste Kempf

src/dvd_reader.c: Fix a couple of fprintf format strings

In DVDReadBlocksPath() there are a couple of fprintf()'s displaying an
offset value, this value is an unsigned int but the format strings had
%d rather than %u.

Signed-off-by: Andrew Clayton <andrew at digital-domain.net>
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

> http://git.videolan.org/gitweb.cgi/libdvdread.git/?a=commit;h=5cdc819bedc1b050c81d81c3b063d37fe54080b8
---

 src/dvd_reader.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/dvd_reader.c b/src/dvd_reader.c
index fb045b3..c67c50c 100644
--- a/src/dvd_reader.c
+++ b/src/dvd_reader.c
@@ -1183,7 +1183,7 @@ static int DVDReadBlocksPath( const dvd_file_t *dvd_file, unsigned int offset,
       if( ( offset + block_count ) <= dvd_file->title_sizes[ i ] ) {
         off = dvdinput_seek( dvd_file->title_devs[ i ], (int)offset );
         if( off < 0 || off != (int)offset ) {
-          fprintf( stderr, "libdvdread: Can't seek to block %d\n",
+          fprintf( stderr, "libdvdread: Can't seek to block %u\n",
                    offset );
           return off < 0 ? off : 0;
         }
@@ -1198,7 +1198,7 @@ static int DVDReadBlocksPath( const dvd_file_t *dvd_file, unsigned int offset,
         /* Read part 1 */
         off = dvdinput_seek( dvd_file->title_devs[ i ], (int)offset );
         if( off < 0 || off != (int)offset ) {
-          fprintf( stderr, "libdvdread: Can't seek to block %d\n",
+          fprintf( stderr, "libdvdread: Can't seek to block %u\n",
                    offset );
           return off < 0 ? off : 0;
         }



More information about the libdvdnav-devel mailing list