summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: dafcd90)
raw | patch | inline | side by side (parent: dafcd90)
author | M. Sean Finney <seanius@users.sourceforge.net> | |
Wed, 25 May 2005 00:30:19 +0000 (00:30 +0000) | ||
committer | M. Sean Finney <seanius@users.sourceforge.net> | |
Wed, 25 May 2005 00:30:19 +0000 (00:30 +0000) |
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1176 f882894a-f735-0410-b71e-b25c423dba1c
plugins/check_tcp.c | patch | blob | history | |
plugins/netutils.c | patch | blob | history | |
plugins/netutils.h | patch | blob | history |
diff --git a/plugins/check_tcp.c b/plugins/check_tcp.c
index 1bf1f4cbb5df97af2a71fb07fd5ecd5671570db8..3087453a76847ea8ec6202f7be286cdd9d21923b 100644 (file)
--- a/plugins/check_tcp.c
+++ b/plugins/check_tcp.c
result = connect_SSL ();
else
#endif
- result = my_connect (server_address, server_port, &sd, PROTOCOL);
+ result = np_net_connect (server_address, server_port, &sd, PROTOCOL);
if (result == STATE_CRITICAL)
return STATE_CRITICAL;
diff --git a/plugins/netutils.c b/plugins/netutils.c
index e7d5ba788b067ca154aeca088e7d1ab04a0191ab..9539a7f0fcc87d826d2c9865cf8b4ccd160e7df5 100644 (file)
--- a/plugins/netutils.c
+++ b/plugins/netutils.c
fd_set readfds;
int recv_length = 0;
- result = my_connect (server_address, server_port, &sd, IPPROTO_TCP);
+ result = np_net_connect (server_address, server_port, &sd, IPPROTO_TCP);
if (result != STATE_OK)
return STATE_CRITICAL;
result = STATE_OK;
- result = my_connect (server_address, server_port, &sd, proto);
+ result = np_net_connect (server_address, server_port, &sd, proto);
if (result != STATE_OK)
return STATE_CRITICAL;
/* opens a tcp or udp connection to a remote host */
int
-my_connect (const char *host_name, int port, int *sd, int proto)
+np_net_connect (const char *host_name, int port, int *sd, int proto)
{
struct addrinfo hints;
struct addrinfo *res, *res0;
diff --git a/plugins/netutils.h b/plugins/netutils.h
index bd5320110d2bed1ca6d3800db9a5e4881d80a57f..1a52eecc13bc7ae7988f246035b0ff656427002f 100644 (file)
--- a/plugins/netutils.h
+++ b/plugins/netutils.h
const char *sbuffer, char *rbuffer, int rsize);
/* my_connect and wrapper macros */
-#define my_tcp_connect(addr, port, s) my_connect(addr, port, s, IPPROTO_TCP)
-#define my_udp_connect(addr, port, s) my_connect(addr, port, s, IPPROTO_UDP)
-int my_connect(const char *address, int port, int *sd, int proto);
+#define my_tcp_connect(addr, port, s) np_net_connect(addr, port, s, IPPROTO_TCP)
+#define my_udp_connect(addr, port, s) np_net_connect(addr, port, s, IPPROTO_UDP)
+int np_net_connect(const char *address, int port, int *sd, int proto);
/* send_request and wrapper macros */
#define send_tcp_request(s, sbuf, rbuf, rsize) \