summaryrefslogtreecommitdiff
path: root/libavcodec/pnm_parser.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavcodec/pnm_parser.c')
-rw-r--r--libavcodec/pnm_parser.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/libavcodec/pnm_parser.c b/libavcodec/pnm_parser.c
index 6607ac7e7f..74f918a94b 100644
--- a/libavcodec/pnm_parser.c
+++ b/libavcodec/pnm_parser.c
@@ -65,8 +65,8 @@ retry:
pnmctx.bytestream_end = pc->buffer + pc->index;
} else {
pnmctx.bytestream_start =
- pnmctx.bytestream = (uint8_t *) buf + skip; /* casts avoid warnings */
- pnmctx.bytestream_end = (uint8_t *) buf + buf_size - skip;
+ pnmctx.bytestream = buf + skip;
+ pnmctx.bytestream_end = buf + buf_size - skip;
}
if (ff_pnm_decode_header(avctx, &pnmctx) < 0) {
if (pnmctx.bytestream < pnmctx.bytestream_end) {
@@ -81,9 +81,9 @@ retry:
goto retry;
}
} else if (pnmctx.type < 4) {
- uint8_t *bs = pnmctx.bytestream;
+ const uint8_t *bs = pnmctx.bytestream;
const uint8_t *end = pnmctx.bytestream_end;
- uint8_t *sync = bs;
+ const uint8_t *sync = bs;
if (pc->index) {
av_assert0(pnmpc->ascii_scan <= end - bs);