1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00

movenc: Fix unfreed memory found by valgrind.

Signed-off-by: Philip Langdale <philipl@overt.org>
This commit is contained in:
Philip Langdale 2012-08-05 08:26:49 -07:00
parent 8d6f46ab2c
commit 3eb56e8434

View File

@ -3154,11 +3154,12 @@ static int mov_write_subtitle_end_packet(AVFormatContext *s,
int stream_index,
int64_t dts) {
AVPacket end;
short data = 0;
int ret;
av_init_packet(&end);
end.size = sizeof (short);
end.data = av_mallocz(end.size);
end.data = (char *)&data;
end.pts = dts;
end.dts = dts;
end.duration = 0;