mirror of https://git.ffmpeg.org/ffmpeg.git
ffmpeg: Use av_freep(), avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
cc63da1223
commit
627f5658b6
4
ffmpeg.c
4
ffmpeg.c
|
@ -516,7 +516,7 @@ static void ffmpeg_cleanup(int ret)
|
||||||
|
|
||||||
if (vstats_file)
|
if (vstats_file)
|
||||||
fclose(vstats_file);
|
fclose(vstats_file);
|
||||||
av_free(vstats_filename);
|
av_freep(&vstats_filename);
|
||||||
|
|
||||||
av_freep(&input_streams);
|
av_freep(&input_streams);
|
||||||
av_freep(&input_files);
|
av_freep(&input_files);
|
||||||
|
@ -2294,7 +2294,7 @@ static void print_sdp(void)
|
||||||
} else {
|
} else {
|
||||||
avio_printf(sdp_pb, "SDP:\n%s", sdp);
|
avio_printf(sdp_pb, "SDP:\n%s", sdp);
|
||||||
avio_close(sdp_pb);
|
avio_close(sdp_pb);
|
||||||
av_free(sdp_filename);
|
av_freep(&sdp_filename);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue