mirror of
https://github.com/yrutschle/sslh.git
synced 2026-10-22 18:12:10 +03:00
-V now outputs compile-time configuration (fix #519)
This commit is contained in:
1 parent
9fadd60eed
commit
70a776fb9a
3 files changed
+44
-3
No files matched your search
@@ -18,6 +18,12 @@ vNEXT:
|
||||
inherit the listen sockets and block a new main
|
||||
process from starting.
|
||||
|
||||
More configuration sanity checks (e.g. using regex
|
||||
or proxyprotocol options if libraries are not compiled in)
|
||||
|
||||
-V now outputs compile-time options so it is
|
||||
possible to know what is compiled in.
|
||||
|
||||
v2.3.0:
|
||||
Added `max_connections` setting to `listen` and
|
||||
`protocol` configuration; see the
|
||||
|
||||
+2
-2
@@ -22,11 +22,11 @@ MAN=sslh.8.gz # man page name
|
||||
# itself
|
||||
|
||||
ifneq ($(strip $(ENABLE_SANITIZER)),)
|
||||
CFLAGS_SAN=-fsanitize=address -fsanitize=leak -fsanitize=undefined -fsanitize=alignment
|
||||
CFLAGS_SAN=-DENABLE_SANITIZER -fsanitize=address -fsanitize=leak -fsanitize=undefined -fsanitize=alignment
|
||||
endif
|
||||
|
||||
ifneq ($(strip $(COV_TEST)),)
|
||||
CFLAGS_COV=-fprofile-arcs -ftest-coverage
|
||||
CFLAGS_COV=-DCOV_TEST -fprofile-arcs -ftest-coverage
|
||||
endif
|
||||
|
||||
CC ?= gcc
|
||||
|
||||
+36
-1
@@ -348,6 +348,41 @@ void close_std(void)
|
||||
}
|
||||
}
|
||||
|
||||
static void print_version(void)
|
||||
{
|
||||
printf("%s %s\n", server_type, VERSION);
|
||||
#ifdef ENABLE_SANITIZER
|
||||
printf("ENABLE_SANITIZER\n");
|
||||
#endif
|
||||
#ifdef ENABLE_REGEX
|
||||
printf("ENABLE_REGEX\n");
|
||||
#endif
|
||||
#ifdef LIBCONFIG
|
||||
printf("LIBCONFIG\n");
|
||||
#endif
|
||||
#ifdef SYSTEMD
|
||||
printf("SYSTEMD\n");
|
||||
#endif
|
||||
#ifdef COV_TEST
|
||||
printf("COV_TEST\n");
|
||||
#endif
|
||||
#ifdef HAVE_LIBWRAP
|
||||
printf("HAVE_LIBWRAP\n");
|
||||
#endif
|
||||
#ifdef HAVE_LANDLOCK
|
||||
printf("HAVE_LANDLOCK\n");
|
||||
#endif
|
||||
#ifdef HAVE_PROXYPROTOCOL
|
||||
printf("HAVE_PROXYPROTOCOL\n");
|
||||
#endif
|
||||
#ifdef HAVE_LIBCAP
|
||||
printf("HAVE_LIBCAP\n");
|
||||
#endif
|
||||
#ifdef HAVE_LIBBSD
|
||||
printf("HAVE_LIBBSD\n");
|
||||
#endif
|
||||
}
|
||||
|
||||
int main(int argc, char *argv[], char* envp[])
|
||||
{
|
||||
int res, num_addr_listen;
|
||||
@@ -363,7 +398,7 @@ int main(int argc, char *argv[], char* envp[])
|
||||
config_finish(&cfg);
|
||||
|
||||
if (cfg.version) {
|
||||
printf("%s %s\n", server_type, VERSION);
|
||||
print_version();
|
||||
exit(0);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user