summaryrefslogtreecommitdiffstats
path: root/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'plugins')
-rw-r--r--plugins/check_pgsql.c1
-rw-r--r--plugins/common.h.in7
-rw-r--r--plugins/netutils.c2
-rw-r--r--plugins/netutils.h.in3
4 files changed, 8 insertions, 5 deletions
diff --git a/plugins/check_pgsql.c b/plugins/check_pgsql.c
index f8419dc..2033b8c 100644
--- a/plugins/check_pgsql.c
+++ b/plugins/check_pgsql.c
@@ -79,7 +79,6 @@ enum {
79#include "config.h" 79#include "config.h"
80#include "common.h" 80#include "common.h"
81#include "utils.h" 81#include "utils.h"
82#include <netdb.h>
83#include <libpq-fe.h> 82#include <libpq-fe.h>
84 83
85int process_arguments (int, char **); 84int process_arguments (int, char **);
diff --git a/plugins/common.h.in b/plugins/common.h.in
index 48e7f6f..09df00d 100644
--- a/plugins/common.h.in
+++ b/plugins/common.h.in
@@ -72,6 +72,13 @@
72 72
73#include <ctype.h> 73#include <ctype.h>
74 74
75#if HAVE_LWRES_NETDB_H
76#include <lwres/netdb.h>
77#elif !HAVE_GETADDRINFO
78#include "getaddrinfo.h"
79#else
80#include <netdb.h>
81#endif
75 82
76/* 83/*
77 * 84 *
diff --git a/plugins/netutils.c b/plugins/netutils.c
index e5d3528..fc85a24 100644
--- a/plugins/netutils.c
+++ b/plugins/netutils.c
@@ -31,10 +31,8 @@
31 31
32#include "config.h" 32#include "config.h"
33#include "common.h" 33#include "common.h"
34#include <sys/socket.h>
35#include <netinet/in.h> 34#include <netinet/in.h>
36#include <arpa/inet.h> 35#include <arpa/inet.h>
37#include <netdb.h>
38 36
39extern int socket_timeout; 37extern int socket_timeout;
40RETSIGTYPE socket_timeout_alarm_handler (int); 38RETSIGTYPE socket_timeout_alarm_handler (int);
diff --git a/plugins/netutils.h.in b/plugins/netutils.h.in
index be4ae24..1907ab7 100644
--- a/plugins/netutils.h.in
+++ b/plugins/netutils.h.in
@@ -34,10 +34,9 @@
34#undef HAVE_STRINGS_H 34#undef HAVE_STRINGS_H
35#undef HAVE_STRING_H 35#undef HAVE_STRING_H
36 36
37#include <sys/socket.h> 37#include "common.h"
38#include <netinet/in.h> 38#include <netinet/in.h>
39#include <arpa/inet.h> 39#include <arpa/inet.h>
40#include <netdb.h>
41 40
42void socket_timeout_alarm_handler (int); 41void socket_timeout_alarm_handler (int);
43 42