thc-ipv6: fix compilation with GCC 15
GCC 15 defaults to C23, where an empty parameter list "()" means
"(void)" instead of an unspecified argument list. This broke thc-ipv6 in
two ways:
- thc-ipv6.h declared thc_open_ipv6() with an empty argument list, so
its prototype became "int(void)" and conflicted with the actual
definition "int thc_open_ipv6(char *interface)" and all of its
callers:
thc-ipv6-lib.c:127:36: error: too many arguments to function
'thc_open_ipv6'; expected 0, have 1
thc-ipv6-lib.c:2555:5: error: conflicting types for 'thc_open_ipv6';
have 'int(char *)'
- The alarming() SIGALRM handlers in detect_sniffer6.c and thcping6.c
were declared with "()", so their type became "void (*)(void)" and no
longer matched the "void (*)(int)" expected by signal():
detect_sniffer6.c:140:19: error: passing argument 2 of 'signal'
from incompatible pointer type [-Wincompatible-pointer-types]
Add patches giving the prototype and the signal handlers their proper
signatures.
Assisted-by: Claude:claude-opus-4-8
Link: https://github.com/openwrt/openwrt/pull/23956
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>