[FFmpeg-devel] [PATCH 3/7] avformat/icecast: Free the right buffer on error

Michael Niedermayer michael at niedermayer.cc
Fri Dec 20 00:27:57 EET 2019

On Sun, Nov 10, 2019 at 05:07:29AM +0100, Andreas Rheinhardt wrote:
> In case an AVBPrint was not complete, icecast_open() would free some
> buffers that have not been allocated yet instead of freeing the data of
> the AVBPrint (if they have been allocated). Because this error does not
> trigger a jump to the general cleanup section any more, one can moreover
> remove a (now unnecessary) initialization of a pointer.
> Furthermore, finalizing an AVBPrint can fail (namely when the string
> inside the AVBPrint has not been allocated yet) and so this needs to be
> checked.
> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at gmail.com>
> ---
>  libavformat/icecast.c | 9 +++++----
>  1 file changed, 5 insertions(+), 4 deletions(-)

will apply


Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

The smallest minority on earth is the individual. Those who deny 
individual rights cannot claim to be defenders of minorities. - Ayn Rand
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: not available
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20191219/ccd14aef/attachment.sig>

More information about the ffmpeg-devel mailing list