v210enc: Fix warning: ‘val’ may be used uninitialized in this function [-Wuninitialized]

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Michael Niedermayer 2011-12-18 00:55:21 +01:00
parent bd35dfeaa0
commit c9dc66375b
1 changed files with 6 additions and 6 deletions

View File

@ -90,13 +90,13 @@ static int encode_frame(AVCodecContext *avctx, unsigned char *buf,
val = CLIP(*y++);
if (w == avctx->width - 2)
bytestream_put_le32(&p, val);
}
if (w < avctx->width - 3) {
val |= (CLIP(*u++) << 10) | (CLIP(*y++) << 20);
bytestream_put_le32(&p, val);
if (w < avctx->width - 3) {
val |= (CLIP(*u++) << 10) | (CLIP(*y++) << 20);
bytestream_put_le32(&p, val);
val = CLIP(*v++) | (CLIP(*y++) << 10);
bytestream_put_le32(&p, val);
val = CLIP(*v++) | (CLIP(*y++) << 10);
bytestream_put_le32(&p, val);
}
}
pdst += stride;