summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 2527943)
raw | patch | inline | side by side (parent: 2527943)
author | Jeremy T. Bouse <undrgrid@users.sourceforge.net> | |
Mon, 30 Jun 2003 18:52:38 +0000 (18:52 +0000) | ||
committer | Jeremy T. Bouse <undrgrid@users.sourceforge.net> | |
Mon, 30 Jun 2003 18:52:38 +0000 (18:52 +0000) |
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@574 f882894a-f735-0410-b71e-b25c423dba1c
plugins/check_ping.c | patch | blob | history | |
plugins/check_ssh.c | patch | blob | history | |
plugins/check_tcp.c | patch | blob | history | |
plugins/netutils.c | patch | blob | history |
diff --git a/plugins/check_ping.c b/plugins/check_ping.c
index 0b2afce56e235774142b315d232fd7569c66a77c..06bf8e767440d1d6f28aadf924b22a518e7ddd3e 100644 (file)
--- a/plugins/check_ping.c
+++ b/plugins/check_ping.c
address_family = AF_INET;
break;
case '6': /* IPv6 only */
+#ifdef USE_IPV6
address_family = AF_INET6;
+#else
+ usage ("IPv6 support not available\n");
+#endif
break;
case 'H': /* hostname */
ptr=optarg;
diff --git a/plugins/check_ssh.c b/plugins/check_ssh.c
index 421fc01c74df794b9fa51c3096ea31d9999ff862..fba3a862b01614579b7902b74112b471af1e2340 100644 (file)
--- a/plugins/check_ssh.c
+++ b/plugins/check_ssh.c
address_family = AF_INET;
break;
case '6':
+#ifdef USE_IPV6
address_family = AF_INET6;
+#else
+ usage ("IPv6 support not available\n");
+#endif
break;
case 'H': /* host */
if (is_host (optarg) == FALSE)
diff --git a/plugins/check_tcp.c b/plugins/check_tcp.c
index b8af1a1d8699a5a47737be484bd4886a4a6167c7..ce4fd31fda539c71c2f75dfe9c94220e198d48fe 100644 (file)
--- a/plugins/check_tcp.c
+++ b/plugins/check_tcp.c
address_family = AF_INET;
break;
case '6':
+#ifdef USE_IPV6
address_family = AF_INET6;
+#else
+ usage ("IPv6 support not available\n");
+#endif
break;
case 'H': /* hostname */
if (is_host (optarg) == FALSE)
diff --git a/plugins/netutils.c b/plugins/netutils.c
index 60410c64345f1759af7790efc23732928190d18c..ea004bb40bafc59409049d2b5af13466d351b50d 100644 (file)
--- a/plugins/netutils.c
+++ b/plugins/netutils.c
int
is_addr (char *address)
{
+#ifdef USE_IPV6
if (is_inet_addr (address) && address_family != AF_INET6)
+#else
+ if (is_inet_addr (address))
+#endif
return (TRUE);
#ifdef USE_IPV6