Commit 37175122 authored by Stephan Holljes's avatar Stephan Holljes Committed by Michael Niedermayer

lavf/tcp.c: Free allocated client URLContext in case of error.

Signed-off-by: 's avatarStephan Holljes <klaxa1337@googlemail.com>
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent 768c0774
......@@ -208,8 +208,10 @@ static int tcp_accept(URLContext *s, URLContext **c)
return ret;
cc = (*c)->priv_data;
ret = ff_accept(sc->fd, sc->listen_timeout, s);
if (ret < 0)
if (ret < 0) {
ffurl_closep(c);
return ret;
}
cc->fd = ret;
return 0;
}
......
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