fftools/ffmpeg: Fix crash when flushing non-fully setup output stream
authorAndreas Rheinhardt <andreas.rheinhardt@outlook.com>
Fri, 8 Oct 2021 07:47:33 +0000 (09:47 +0200)
committerAndreas Rheinhardt <andreas.rheinhardt@outlook.com>
Fri, 8 Oct 2021 10:06:00 +0000 (12:06 +0200)
commitfb215798c7a72b32e889b72efd018f26bb3f88ce
tree33d6be929f762e8a9d9af92024d62be9ebae6eb4
parent6d72126e9ba857c68f0a363729ad67097355c090
fftools/ffmpeg: Fix crash when flushing non-fully setup output stream

The output stream's packet may not have been allocated
at that point. This happens when quitting in the following command line:
$ ./ffmpeg -lavfi abuffer=sample_fmt=u8:sample_rate=48000:channel_layout=stereo -f null -

Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
fftools/ffmpeg.c