MCPcopy Index your code
hub / github.com/RsyncProject/rsync / noop_io_until_death

Function noop_io_until_death

io.c:943–962  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

941}
942
943void noop_io_until_death(void)
944{
945 char buf[1024];
946
947 if (!iobuf.in.buf || !iobuf.out.buf || iobuf.in_fd < 0 || iobuf.out_fd < 0 || kluge_around_eof)
948 return;
949
950 /* If we're talking to a daemon over a socket, don't short-circuit this logic */
951 if (msgs2stderr && daemon_connection >= 0)
952 return;
953
954 kluge_around_eof = 2;
955 /* Setting an I/O timeout ensures that if something inexplicably weird
956 * happens, we won't hang around forever. */
957 if (!io_timeout)
958 set_io_timeout(60);
959
960 while (1)
961 read_buf(iobuf.in_fd, buf, sizeof buf);
962}
963
964/* Buffer a message for the multiplexed output stream. Is not used for (normal) MSG_DATA. */
965int send_msg(enum msgcode code, const char *buf, size_t len, int convert)

Callers 1

_exit_cleanupFunction · 0.85

Calls 2

set_io_timeoutFunction · 0.85
read_bufFunction · 0.70

Tested by

no test coverage detected