mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-01-19 22:01:00 +00:00
qt-faststart: Avoid leaking memory if encountering a file with double ftyp atoms
Originally committed as revision 23065 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
17be16a336
commit
6ad533b7cb
@ -116,6 +116,7 @@ int main(int argc, char *argv[])
|
|||||||
/* keep ftyp atom */
|
/* keep ftyp atom */
|
||||||
if (atom_type == FTYP_ATOM) {
|
if (atom_type == FTYP_ATOM) {
|
||||||
ftyp_atom_size = atom_size;
|
ftyp_atom_size = atom_size;
|
||||||
|
free(ftyp_atom);
|
||||||
ftyp_atom = malloc(ftyp_atom_size);
|
ftyp_atom = malloc(ftyp_atom_size);
|
||||||
if (!ftyp_atom) {
|
if (!ftyp_atom) {
|
||||||
printf ("could not allocate %"PRIu64" byte for ftyp atom\n",
|
printf ("could not allocate %"PRIu64" byte for ftyp atom\n",
|
||||||
|
Loading…
Reference in New Issue
Block a user