Commit 18963d60 authored by mstorsjo's avatar mstorsjo

ffserver: Fix another memory leak

Don't allocate st->codec, it will be overwritten by the memcpy a few
lines further down.

Fix by Howard Chu, hyc at highlandsun dot com


git-svn-id: file:///var/local/repositories/ffmpeg/trunk@23291 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent c7f13a0f
...@@ -3381,7 +3381,6 @@ static int rtp_new_av_stream(HTTPContext *c, ...@@ -3381,7 +3381,6 @@ static int rtp_new_av_stream(HTTPContext *c,
st = av_mallocz(sizeof(AVStream)); st = av_mallocz(sizeof(AVStream));
if (!st) if (!st)
goto fail; goto fail;
st->codec= avcodec_alloc_context();
ctx->nb_streams = 1; ctx->nb_streams = 1;
ctx->streams[0] = st; ctx->streams[0] = st;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment