[FFmpeg-trac] #3554(avdevice:new): lavfi.c: variable 'sink' is used uninitialized whenever type != AVMEDIA_TYPE_{AUDIO, VIDEO}
FFmpeg
trac at avcodec.org
Mon Apr 14 15:12:20 CEST 2014
#3554: lavfi.c: variable 'sink' is used uninitialized whenever type !=
AVMEDIA_TYPE_{AUDIO,VIDEO}
-------------------------------------+------------------------------------
Reporter: jeremyhu | Owner:
Type: defect | Status: new
Priority: normal | Component: avdevice
Version: unspecified | Resolution:
Keywords: | Blocked By:
Blocking: | Reproduced by developer: 0
Analyzed by developer: 0 |
-------------------------------------+------------------------------------
Comment (by DonMoir):
Replying to [comment:4 michael]:
> doesnt this a few lines further up:
> {{{if (type != AVMEDIA_TYPE_VIDEO && type != AVMEDIA_TYPE_AUDIO) { }}}
> make the else case impossible ?
Seems so, so change to:
AVFilterContext *sink;
...
if (type == AVMEDIA_TYPE_VIDEO) {
...
... ok sink set
}
-else if (type == AVMEDIA_TYPE_AUDIO) {
+else {
...
... ok sink set
}
--
Ticket URL: <https://trac.ffmpeg.org/ticket/3554#comment:5>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker
More information about the FFmpeg-trac
mailing list