mirror of https://git.ffmpeg.org/ffmpeg.git
lavf/tcp.c: Free allocated client URLContext in case of error.
Signed-off-by: Stephan Holljes <klaxa1337@googlemail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
parent
768c0774d8
commit
3717512282
|
@ -208,8 +208,10 @@ static int tcp_accept(URLContext *s, URLContext **c)
|
||||||
return ret;
|
return ret;
|
||||||
cc = (*c)->priv_data;
|
cc = (*c)->priv_data;
|
||||||
ret = ff_accept(sc->fd, sc->listen_timeout, s);
|
ret = ff_accept(sc->fd, sc->listen_timeout, s);
|
||||||
if (ret < 0)
|
if (ret < 0) {
|
||||||
|
ffurl_closep(c);
|
||||||
return ret;
|
return ret;
|
||||||
|
}
|
||||||
cc->fd = ret;
|
cc->fd = ret;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue