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

Function tcp_write

libavformat/tcp.c:285–297  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

283}
284
285static int tcp_write(URLContext *h, const uint8_t *buf, int size)
286{
287 TCPContext *s = h->priv_data;
288 int ret;
289
290 if (!(h->flags & AVIO_FLAG_NONBLOCK)) {
291 ret = ff_network_wait_fd_timeout(s->fd, 1, h->rw_timeout, &h->interrupt_callback);
292 if (ret)
293 return ret;
294 }
295 ret = send(s->fd, buf, size, MSG_NOSIGNAL);
296 return ret < 0 ? ff_neterrno() : ret;
297}
298
299static int tcp_shutdown(URLContext *h, int flags)
300{

Callers

nothing calls this directly

Calls 2

ff_neterrnoFunction · 0.85

Tested by

no test coverage detected