diff --git a/src/dec/vp8.c b/src/dec/vp8.c index 7b0e38ea..ff3c7d1f 100644 --- a/src/dec/vp8.c +++ b/src/dec/vp8.c @@ -82,7 +82,7 @@ int VP8SetError(VP8Decoder* const dec, //------------------------------------------------------------------------------ -int VP8GetInfo(const uint8_t* data, uint32_t data_size, uint32_t chunk_size, +int VP8GetInfo(const uint8_t* data, size_t data_size, size_t chunk_size, int* width, int* height) { if (data_size < 10) { return 0; // not enough data @@ -173,7 +173,7 @@ static int ParseSegmentHeader(VP8BitReader* br, // is returned, and this is an unrecoverable error. // If the partitions were positioned ok, VP8_STATUS_OK is returned. static VP8StatusCode ParsePartitions(VP8Decoder* const dec, - const uint8_t* buf, uint32_t size) { + const uint8_t* buf, size_t size) { VP8BitReader* const br = &dec->br_; const uint8_t* sz = buf; const uint8_t* buf_end = buf + size; @@ -244,7 +244,7 @@ static int ParseFilterHeader(VP8BitReader* br, VP8Decoder* const dec) { // Topmost call int VP8GetHeaders(VP8Decoder* const dec, VP8Io* const io) { const uint8_t* buf; - uint32_t buf_size; + size_t buf_size; VP8FrameHeader* frm_hdr; VP8PictureHeader* pic_hdr; VP8BitReader* br; diff --git a/src/dec/vp8i.h b/src/dec/vp8i.h index d3aeb35e..af392d8e 100644 --- a/src/dec/vp8i.h +++ b/src/dec/vp8i.h @@ -294,8 +294,8 @@ int VP8SetError(VP8Decoder* const dec, // width and height. Returns 0 in case of formatting error. *width/*height // can be passed NULL. int VP8GetInfo(const uint8_t* data, - uint32_t data_size, // data available so far - uint32_t chunk_size, // total data size expect in the chunk + size_t data_size, // data available so far + size_t chunk_size, // total data size expect in the chunk int *width, int *height); // in tree.c diff --git a/src/dec/webpi.h b/src/dec/webpi.h index 3f6172af..7dba85f9 100644 --- a/src/dec/webpi.h +++ b/src/dec/webpi.h @@ -59,7 +59,7 @@ void WebPResetDecParams(WebPDecParams* const params); // Structure storing a description of the RIFF headers. typedef struct { const uint8_t* data; // input buffer - uint32_t data_size; // input buffer size + size_t data_size; // input buffer size size_t offset; // offset to main data chunk (VP8 or VP8L) const uint8_t* alpha_data; // points to alpha chunk (if present) uint32_t alpha_data_size; // alpha chunk size