Git Mailing List Archive mirror
 help / color / mirror / Atom feed
blob c866e9c9a4e53fb16d0a524e2751e702ac4054dc 1474 bytes (raw)
name: daemon-utils.h 	 # note: path name is non-authoritative(*)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
 
#ifndef DAEMON_UTILS_H
#define DAEMON_UTILS_H

#include "git-compat-util.h"
#include "run-command.h"
#include "string-list.h"

typedef void (*log_fn)(const char *msg, ...);

struct socketlist {
	int *list;
	size_t nr;
	size_t alloc;
};

/* Enable sending of keep-alive messages on the socket. */
void set_keep_alive(int sockfd, log_fn logerror);

/* Setup a number of sockets to listen on the provided addresses. */
void socksetup(struct string_list *listen_addr, int listen_port,
	       struct socketlist *socklist, int reuseaddr,
	       log_fn logerror);

struct child {
	struct child *next;
	struct child_process cld;
	struct sockaddr_storage address;
};

/*
 * Add the child_process to the set of children and increment the number of
 * live children.
 */
void add_child(struct child_process *cld, struct sockaddr *addr, socklen_t addrlen,
	       struct child *first_child, unsigned int *live_children);

/*
 * Kill the newest connection from a duplicate IP.
 *
 * This function should be called if the number of connections grows
 * past the maximum number of allowed connections.
 */
void kill_some_child(struct child *first_child);

/*
 * Check for children that have disconnected and remove them from the
 * active set, decrementing the number of live children.
 *
 * Optionally log the child PID that disconnected by passing a loginfo
 * function.
 */
void check_dead_children(struct child *first_child, unsigned int *live_children,
			 log_fn loginfo);

#endif

debug log:

solving c866e9c9a4e ...
found c866e9c9a4e in https://80x24.org/lore/git/9967401c972cab547d7619a208c3a0e6a3923cd4.1674252531.git.gitgitgadget@gmail.com/ ||
	https://80x24.org/lore/git/9967401c972cab547d7619a208c3a0e6a3923cd4.1674012618.git.gitgitgadget@gmail.com/
found 97e5cae20b8 in https://80x24.org/lore/git/b6ba344a671c674d1caf577194eddd66eb7e1415.1674252531.git.gitgitgadget@gmail.com/ ||
	https://80x24.org/lore/git/b6ba344a671c674d1caf577194eddd66eb7e1415.1674012618.git.gitgitgadget@gmail.com/
found 6710a2a6dc0 in https://80x24.org/lore/git/74b0de14185120c9d53d7470e59f57fa20a1927f.1673475190.git.gitgitgadget@gmail.com/ ||
	https://80x24.org/lore/git/74b0de14185120c9d53d7470e59f57fa20a1927f.1674252531.git.gitgitgadget@gmail.com/ ||
	https://80x24.org/lore/git/74b0de14185120c9d53d7470e59f57fa20a1927f.1674012618.git.gitgitgadget@gmail.com/

applying [1/3] https://80x24.org/lore/git/74b0de14185120c9d53d7470e59f57fa20a1927f.1673475190.git.gitgitgadget@gmail.com/
diff --git a/daemon-utils.h b/daemon-utils.h
new file mode 100644
index 00000000000..6710a2a6dc0

Checking patch daemon-utils.h...
Applied patch daemon-utils.h cleanly.

skipping https://80x24.org/lore/git/74b0de14185120c9d53d7470e59f57fa20a1927f.1674252531.git.gitgitgadget@gmail.com/ for 6710a2a6dc0
skipping https://80x24.org/lore/git/74b0de14185120c9d53d7470e59f57fa20a1927f.1674012618.git.gitgitgadget@gmail.com/ for 6710a2a6dc0
index at:
100644 6710a2a6dc0c3737663981efb1e3d073148160e7	daemon-utils.h

applying [2/3] https://80x24.org/lore/git/b6ba344a671c674d1caf577194eddd66eb7e1415.1674252531.git.gitgitgadget@gmail.com/
diff --git a/daemon-utils.h b/daemon-utils.h
index 6710a2a6dc0..97e5cae20b8 100644

Checking patch daemon-utils.h...
Applied patch daemon-utils.h cleanly.

skipping https://80x24.org/lore/git/b6ba344a671c674d1caf577194eddd66eb7e1415.1674012618.git.gitgitgadget@gmail.com/ for 97e5cae20b8
index at:
100644 97e5cae20b837d25ebc7e792ae45c82ba322195d	daemon-utils.h

applying [3/3] https://80x24.org/lore/git/9967401c972cab547d7619a208c3a0e6a3923cd4.1674252531.git.gitgitgadget@gmail.com/
diff --git a/daemon-utils.h b/daemon-utils.h
index 97e5cae20b8..c866e9c9a4e 100644

Checking patch daemon-utils.h...
Applied patch daemon-utils.h cleanly.

skipping https://80x24.org/lore/git/9967401c972cab547d7619a208c3a0e6a3923cd4.1674012618.git.gitgitgadget@gmail.com/ for c866e9c9a4e
index at:
100644 c866e9c9a4e53fb16d0a524e2751e702ac4054dc	daemon-utils.h

(*) Git path names are given by the tree(s) the blob belongs to.
    Blobs themselves have no identifier aside from the hash of its contents.^

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).