Use volatile sig_atomic_t instead of int

This commit is contained in:
2022-10-13 15:42:31 +02:00
parent 100eb1597d
commit 92779e5dba
3 changed files with 4 additions and 3 deletions

@ -10,6 +10,7 @@
#include <sys/time.h>
#include <maxminddb.h>
#include <signal.h>
#define NUM_SOCKETS 2
#define MAX_CHILDREN 1024
@ -25,7 +26,7 @@ extern int sockets[NUM_SOCKETS];
extern pid_t children[MAX_CHILDREN];
extern MMDB_s mmdbs[MAX_MMDB];
extern int server_keep_alive;
extern volatile sig_atomic_t server_keep_alive;
extern char *log_client_prefix, *log_conn_prefix, *log_req_prefix, *client_geoip;
extern char *client_addr_str, *client_addr_str_ptr, *server_addr_str, *server_addr_str_ptr, *client_host_str;
extern struct timeval client_timeout;