MCPcopy Create free account
hub / github.com/FFmpeg/FFmpeg / tcp_accept

Function tcp_accept

libavformat/tcp.c:251–267  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

249}
250
251static int tcp_accept(URLContext *s, URLContext **c)
252{
253 TCPContext *sc = s->priv_data;
254 TCPContext *cc;
255 int ret;
256 av_assert0(sc->listen);
257 if ((ret = ffurl_alloc(c, s->filename, s->flags, &s->interrupt_callback)) < 0)
258 return ret;
259 cc = (*c)->priv_data;
260 ret = ff_accept(sc->fd, sc->listen_timeout, s);
261 if (ret < 0) {
262 ffurl_closep(c);
263 return ret;
264 }
265 cc->fd = ret;
266 return 0;
267}
268
269static int tcp_read(URLContext *h, uint8_t *buf, int size)
270{

Callers

nothing calls this directly

Calls 3

ffurl_allocFunction · 0.85
ff_acceptFunction · 0.85
ffurl_closepFunction · 0.85

Tested by

no test coverage detected