Commit 7b48bf95 authored by Vittorio Giovara's avatar Vittorio Giovara

wtv: clean memory on error

CC: libav-stable@libav.org
Bug-Id: CID 718002
parent 9fbc613f
......@@ -632,8 +632,10 @@ static AVStream * new_stream(AVFormatContext *s, AVStream *st, int sid, int code
if (!wst)
return NULL;
st = avformat_new_stream(s, NULL);
if (!st)
if (!st) {
av_free(wst);
return NULL;
}
st->id = sid;
st->priv_data = wst;
}
......
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