]> git.sesse.net Git - ffmpeg/commit
avformat/mpeg: Don't free unintialized pointer
authorAndreas Rheinhardt <andreas.rheinhardt@gmail.com>
Tue, 22 Oct 2019 13:16:41 +0000 (15:16 +0200)
committerJames Almer <jamrial@gmail.com>
Thu, 24 Oct 2019 18:51:20 +0000 (15:51 -0300)
commit262eef6b899ca39f80296e6eb701e895549d8a83
treee6b37938420df7a7636c20ef567e46cea20c85c1
parent531fbce0b281be2450bbf0230c2de539230a7d84
avformat/mpeg: Don't free unintialized pointer

In order to fix a potential memleak upon failure, 0b8956b2 made sure that
a buffer given by a pointer was freed upon error. But this pointer was
only initialized upon use and in several cases (Clang gives no fewer
than 13 -Wsometimes-uninitialized warnings) this meant that an
uninitialized pointer was used to free a buffer. So initialize the
pointer.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
libavformat/mpeg.c