git/unix-stream-server.c

#include "git-compat-util.h"
#include "lockfile.h"
#include "unix-socket.h"
#include "unix-stream-server.h"

#define DEFAULT_LOCK_TIMEOUT

/*
 * Try to connect to a unix domain socket at `path` (if it exists) and
 * see if there is a server listening.
 *
 * We don't know if the socket exists, whether a server died and
 * failed to cleanup, or whether we have a live server listening, so
 * we "poke" it.
 *
 * We immediately hangup without sending/receiving any data because we
 * don't know anything about the protocol spoken and don't want to
 * block while writing/reading data.  It is sufficient to just know
 * that someone is listening.
 */
static int is_another_server_alive(const char *path,
				   const struct unix_stream_listen_opts *opts)
{}

int unix_ss_create(const char *path,
		   const struct unix_stream_listen_opts *opts,
		   long timeout_ms,
		   struct unix_ss_socket **new_server_socket)
{}

void unix_ss_free(struct unix_ss_socket *server_socket)
{}

int unix_ss_was_stolen(struct unix_ss_socket *server_socket)
{}