Commit 0372dd3a authored by philipjsg's avatar philipjsg

Applied Roumen Petrov patch to fix crash/memory leak


git-svn-id: file:///var/local/repositories/ffmpeg/trunk@1758 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent 92a896b0
......@@ -748,9 +748,6 @@ static void close_connection(HTTPContext *c)
ctx = &c->fmt_ctx;
for(i=0; i<ctx->nb_streams; i++)
av_free(ctx->streams[i]) ;
if (!c->last_packet_sent) {
if (ctx->oformat) {
/* prepare header */
......@@ -761,6 +758,9 @@ static void close_connection(HTTPContext *c)
}
}
for(i=0; i<ctx->nb_streams; i++)
av_free(ctx->streams[i]) ;
if (c->stream)
current_bandwidth -= c->stream->bandwidth;
av_freep(&c->pb_buffer);
......
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