On Sun, Nov 9, 2014 at 5:10 PM, Justin Ruggles <[email protected]> wrote: > On 11/09/2014 02:48 AM, Vittorio Giovara wrote: >> >> --- >> libavcodec/tiffenc.c | 2 +- >> 1 file changed, 1 insertion(+), 1 deletion(-) >> >> diff --git a/libavcodec/tiffenc.c b/libavcodec/tiffenc.c >> index f794961..cde7c12 100644 >> --- a/libavcodec/tiffenc.c >> +++ b/libavcodec/tiffenc.c >> @@ -214,7 +214,7 @@ static int encode_frame(AVCodecContext *avctx, >> AVPacket *pkt, >> int bytes_per_row; >> uint32_t res[2] = { 72, 1 }; // image resolution (72/1) >> uint16_t bpp_tab[] = { 8, 8, 8, 8 }; >> - int ret; >> + int ret = 0; >> int is_yuv = 0; >> uint8_t *yuv_line = NULL; >> int shift_h, shift_v; >> > > 'ret' can only be used without initialization if s->height <= 0, which can > only happen if avctx->height <= 0, which is validated elsewhere, so I can > see why this tripped up coverity. Doesn't hurt to still initialize it > though.
I'll add this message to the commit log, thanks -- Vittorio _______________________________________________ libav-devel mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-devel
