summaryrefslogtreecommitdiffstats
path: root/plugins/netutils.c
diff options
context:
space:
mode:
authorBenoit Mortier <opensides@users.sourceforge.net>2006-06-18 19:36:48 (GMT)
committerBenoit Mortier <opensides@users.sourceforge.net>2006-06-18 19:36:48 (GMT)
commitf9394308c9c372bcf419a311c61ba420247ae613 (patch)
tree616e0bebcbe821703dff207f7f1b704c2deae349 /plugins/netutils.c
parentcbbfed30eb01a702b2e61c0abcb64c834e73d654 (diff)
downloadmonitoring-plugins-f9394308c9c372bcf419a311c61ba420247ae613.tar.gz
updating help and usage and license
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1434 f882894a-f735-0410-b71e-b25c423dba1c
Diffstat (limited to 'plugins/netutils.c')
-rw-r--r--plugins/netutils.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/plugins/netutils.c b/plugins/netutils.c
index b4c3944..a3a241d 100644
--- a/plugins/netutils.c
+++ b/plugins/netutils.c
@@ -76,7 +76,7 @@ process_tcp_request2 (const char *server_address, int server_port,
76 76
77 send_result = send (sd, send_buffer, strlen (send_buffer), 0); 77 send_result = send (sd, send_buffer, strlen (send_buffer), 0);
78 if (send_result<0 || (size_t)send_result!=strlen(send_buffer)) { 78 if (send_result<0 || (size_t)send_result!=strlen(send_buffer)) {
79 printf (_("Send failed\n")); 79 printf ("%s\n", _("Send failed"));
80 result = STATE_WARNING; 80 result = STATE_WARNING;
81 } 81 }
82 82
@@ -93,7 +93,7 @@ process_tcp_request2 (const char *server_address, int server_port,
93 if (!FD_ISSET (sd, &readfds)) { /* it hasn't */ 93 if (!FD_ISSET (sd, &readfds)) { /* it hasn't */
94 if (!recv_length) { 94 if (!recv_length) {
95 strcpy (recv_buffer, ""); 95 strcpy (recv_buffer, "");
96 printf (_("No data was received from host!\n")); 96 printf ("%s\n", _("No data was received from host!"));
97 result = STATE_WARNING; 97 result = STATE_WARNING;
98 } 98 }
99 else { /* this one failed, but previous ones worked */ 99 else { /* this one failed, but previous ones worked */
@@ -190,7 +190,7 @@ np_net_connect (const char *host_name, int port, int *sd, int proto)
190 *sd = socket (r->ai_family, socktype, r->ai_protocol); 190 *sd = socket (r->ai_family, socktype, r->ai_protocol);
191 191
192 if (*sd < 0) { 192 if (*sd < 0) {
193 printf (_("Socket creation failed\n")); 193 printf ("%s\n", _("Socket creation failed"));
194 freeaddrinfo (r); 194 freeaddrinfo (r);
195 return STATE_UNKNOWN; 195 return STATE_UNKNOWN;
196 } 196 }
@@ -267,7 +267,7 @@ send_request (int sd, int proto, const char *send_buffer, char *recv_buffer, int
267 267
268 send_result = send (sd, send_buffer, strlen (send_buffer), 0); 268 send_result = send (sd, send_buffer, strlen (send_buffer), 0);
269 if (send_result<0 || (size_t)send_result!=strlen(send_buffer)) { 269 if (send_result<0 || (size_t)send_result!=strlen(send_buffer)) {
270 printf (_("Send failed\n")); 270 printf ("%s\n", _("Send failed"));
271 result = STATE_WARNING; 271 result = STATE_WARNING;
272 } 272 }
273 273
@@ -282,7 +282,7 @@ send_request (int sd, int proto, const char *send_buffer, char *recv_buffer, int
282 /* make sure some data has arrived */ 282 /* make sure some data has arrived */
283 if (!FD_ISSET (sd, &readfds)) { 283 if (!FD_ISSET (sd, &readfds)) {
284 strcpy (recv_buffer, ""); 284 strcpy (recv_buffer, "");
285 printf (_("No data was received from host!\n")); 285 printf ("%s\n", _("No data was received from host!"));
286 result = STATE_WARNING; 286 result = STATE_WARNING;
287 } 287 }
288 288
@@ -291,7 +291,7 @@ send_request (int sd, int proto, const char *send_buffer, char *recv_buffer, int
291 if (recv_result == -1) { 291 if (recv_result == -1) {
292 strcpy (recv_buffer, ""); 292 strcpy (recv_buffer, "");
293 if (proto != IPPROTO_TCP) 293 if (proto != IPPROTO_TCP)
294 printf (_("Receive failed\n")); 294 printf ("%s\n", _("Receive failed"));
295 result = STATE_WARNING; 295 result = STATE_WARNING;
296 } 296 }
297 else 297 else