From 55144ccb0ac48bd2db0b907a8e8123b2befe83d1 Mon Sep 17 00:00:00 2001 From: Jeff Hostetler Date: Mon, 15 Mar 2021 21:08:25 +0000 Subject: unix-socket: add backlog size option to unix_stream_listen() Update `unix_stream_listen()` to take an options structure to override default behaviors. This commit includes the size of the `listen()` backlog. Signed-off-by: Jeff Hostetler Signed-off-by: Junio C Hamano --- builtin/credential-cache--daemon.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'builtin') diff --git a/builtin/credential-cache--daemon.c b/builtin/credential-cache--daemon.c index c61f123a3b..4c6c89ab0d 100644 --- a/builtin/credential-cache--daemon.c +++ b/builtin/credential-cache--daemon.c @@ -203,9 +203,10 @@ static int serve_cache_loop(int fd) static void serve_cache(const char *socket_path, int debug) { + struct unix_stream_listen_opts opts = UNIX_STREAM_LISTEN_OPTS_INIT; int fd; - fd = unix_stream_listen(socket_path); + fd = unix_stream_listen(socket_path, &opts); if (fd < 0) die_errno("unable to bind to '%s'", socket_path); -- cgit v1.3-5-g9baa