mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-09-21 05:31:25 +02:00
40 lines
841 B
Diff
40 lines
841 B
Diff
--- a/src/main.c
|
|
+++ b/src/main.c
|
|
@@ -25,7 +25,9 @@
|
|
#include <string.h>
|
|
#include <errno.h>
|
|
#include <unistd.h>
|
|
+#ifdef HAVE_EXECINFO_H
|
|
#include <execinfo.h>
|
|
+#endif
|
|
|
|
#include "config.h"
|
|
#include "objects.h"
|
|
@@ -88,6 +90,7 @@
|
|
exit(EXIT_SUCCESS);
|
|
}
|
|
|
|
+#ifdef HAVE_EXECINFO_H
|
|
static void nftlb_trace() {
|
|
void *buffer[255];
|
|
char **str;
|
|
@@ -109,6 +112,7 @@
|
|
|
|
exit(EXIT_FAILURE);
|
|
}
|
|
+#endif
|
|
|
|
int main(int argc, char *argv[])
|
|
{
|
|
@@ -166,9 +170,7 @@
|
|
|
|
if (signal(SIGINT, nftlb_sighandler) == SIG_ERR ||
|
|
signal(SIGTERM, nftlb_sighandler) == SIG_ERR ||
|
|
- signal(SIGPIPE, SIG_IGN) == SIG_ERR ||
|
|
- signal(SIGABRT, nftlb_trace) == SIG_ERR ||
|
|
- signal(SIGSEGV, nftlb_trace) == SIG_ERR) {
|
|
+ signal(SIGPIPE, SIG_IGN) == SIG_ERR) {
|
|
tools_printlog(LOG_ERR, "Error assigning signals");
|
|
return EXIT_FAILURE;
|
|
}
|