[libbluray-devel] Use correct type for file offsets

hpi1 git at videolan.org
Fri Nov 7 12:12:32 CET 2014


libbluray | branch: master | hpi1 <hpi1 at anonymous.org> | Fri Nov  7 12:58:51 2014 +0200| [fb6695e4925640e3cb6d7dfee27755cd87e33015] | committer: hpi1

Use correct type for file offsets

> http://git.videolan.org/gitweb.cgi/libbluray.git/?a=commit;h=fb6695e4925640e3cb6d7dfee27755cd87e33015
---

 src/libbluray/bdnav/clpi_parse.c |    8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/src/libbluray/bdnav/clpi_parse.c b/src/libbluray/bdnav/clpi_parse.c
index a963ec0..a1ed531 100644
--- a/src/libbluray/bdnav/clpi_parse.c
+++ b/src/libbluray/bdnav/clpi_parse.c
@@ -51,7 +51,8 @@ _human_readable_sig(char *sig, uint32_t s1, uint32_t s2)
 static int
 _parse_stream_attr(BITSTREAM *bits, CLPI_PROG_STREAM *ss)
 {
-    int len, pos;
+    off_t pos;
+    int len;
 
     if (!bs_is_align(bits, 0x07)) {
         BD_DEBUG(DBG_NAV | DBG_CRIT, "_parse_stream_attr(): Stream alignment error\n");
@@ -144,7 +145,8 @@ _parse_header(BITSTREAM *bits, CLPI_CL *cl)
 static int
 _parse_clipinfo(BITSTREAM *bits, CLPI_CL *cl)
 {
-    int len, pos;
+    off_t pos;
+    int len;
     int ii;
 
     bs_seek_byte(bits, 40);
@@ -320,7 +322,7 @@ _parse_cpi(BITSTREAM *bits, CLPI_CPI *cpi)
 
     bs_skip(bits, 12);
     cpi->type = bs_read(bits, 4);
-    ep_map_pos = bs_pos(bits) >> 3;
+    ep_map_pos = (uint32_t)(bs_pos(bits) >> 3);
 
     // EP Map starts here
     bs_skip(bits, 8);



More information about the libbluray-devel mailing list