diff options
author | Reimar Döffinger <Reimar.Doeffinger@gmx.de> | 2009-04-17 08:42:08 +0000 |
---|---|---|
committer | Reimar Döffinger <Reimar.Doeffinger@gmx.de> | 2009-04-17 08:42:08 +0000 |
commit | 8b5ec0875c8d00d62034ed1df7188b7c75baba3a (patch) | |
tree | a6638e38c2482e50a0e9981032f20ec5d3ee0b38 /libavcodec/eatgq.c | |
parent | a7c6e1171b1984b949464c4d9070f10a1fd43d6d (diff) | |
download | ffmpeg-8b5ec0875c8d00d62034ed1df7188b7c75baba3a.tar.gz |
Change tgq_decode_mb function arguments from using int8_t to uint8_t, this does
not really change the code (x86_64/gcc-4.3.3 results stay unchanged) but avoids
several casts and an aliasing violation that broke decoding at least on
PPC64/gcc-4.1.2.
Originally committed as revision 18541 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/eatgq.c')
-rw-r--r-- | libavcodec/eatgq.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/libavcodec/eatgq.c b/libavcodec/eatgq.c index bc1a072ecd..a854d5f4f8 100644 --- a/libavcodec/eatgq.c +++ b/libavcodec/eatgq.c @@ -140,13 +140,13 @@ static void tgq_idct_put_mb_dconly(TgqContext *s, int mb_x, int mb_y, const int8 } } -static void tgq_decode_mb(TgqContext *s, int mb_y, int mb_x, const int8_t **bs, const int8_t *buf_end){ +static void tgq_decode_mb(TgqContext *s, int mb_y, int mb_x, const uint8_t **bs, const uint8_t *buf_end){ int mode; int i; int8_t dc[6]; DCTELEM block[6][64]; - mode = bytestream_get_byte((const uint8_t**)bs); + mode = bytestream_get_byte(bs); if (mode>buf_end-*bs) { av_log(s->avctx, AV_LOG_ERROR, "truncated macroblock\n"); return; @@ -228,7 +228,7 @@ static int tgq_decode_frame(AVCodecContext *avctx, for (y=0; y<(avctx->height+15)/16; y++) for (x=0; x<(avctx->width+15)/16; x++) - tgq_decode_mb(s, y, x, (const int8_t**)&buf, (const int8_t*)buf_end); + tgq_decode_mb(s, y, x, &buf, buf_end); *data_size = sizeof(AVFrame); *(AVFrame*)data = s->frame; |