MCPcopy Create free account
hub / github.com/git/git / set_keep_alive

Function set_keep_alive

daemon.c:736–745  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

734}
735
736static void set_keep_alive(int sockfd)
737{
738 int ka = 1;
739
740 if (setsockopt(sockfd, SOL_SOCKET, SO_KEEPALIVE, &ka, sizeof(ka)) < 0) {
741 if (errno != ENOTSOCK)
742 logerror("unable to set SO_KEEPALIVE on socket: %s",
743 strerror(errno));
744 }
745}
746
747static int execute(void)
748{

Callers 2

executeFunction · 0.85
setup_named_sockFunction · 0.85

Calls 1

logerrorFunction · 0.85

Tested by

no test coverage detected