diff options
Diffstat (limited to 'plugins/netutils.c')
-rw-r--r-- | plugins/netutils.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/plugins/netutils.c b/plugins/netutils.c index 6702b13f..1231c1ef 100644 --- a/plugins/netutils.c +++ b/plugins/netutils.c | |||
@@ -45,9 +45,9 @@ void | |||
45 | socket_timeout_alarm_handler (int sig) | 45 | socket_timeout_alarm_handler (int sig) |
46 | { | 46 | { |
47 | if (sig == SIGALRM) | 47 | if (sig == SIGALRM) |
48 | printf ("CRITICAL - Socket timeout after %d seconds\n", socket_timeout); | 48 | printf (_("CRITICAL - Socket timeout after %d seconds\n"), socket_timeout); |
49 | else | 49 | else |
50 | printf ("CRITICAL - Abnormal timeout after %d seconds\n", socket_timeout); | 50 | printf (_("CRITICAL - Abnormal timeout after %d seconds\n"), socket_timeout); |
51 | 51 | ||
52 | exit (STATE_CRITICAL); | 52 | exit (STATE_CRITICAL); |
53 | } | 53 | } |
@@ -106,7 +106,7 @@ process_tcp_request2 (const char *server_address, int server_port, | |||
106 | 106 | ||
107 | send_result = send (sd, send_buffer, strlen (send_buffer), 0); | 107 | send_result = send (sd, send_buffer, strlen (send_buffer), 0); |
108 | if (send_result<0 || (size_t)send_result!=strlen(send_buffer)) { | 108 | if (send_result<0 || (size_t)send_result!=strlen(send_buffer)) { |
109 | printf ("Send failed\n"); | 109 | printf (_("Send failed\n")); |
110 | result = STATE_WARNING; | 110 | result = STATE_WARNING; |
111 | } | 111 | } |
112 | 112 | ||
@@ -123,7 +123,7 @@ process_tcp_request2 (const char *server_address, int server_port, | |||
123 | if (!FD_ISSET (sd, &readfds)) { /* it hasn't */ | 123 | if (!FD_ISSET (sd, &readfds)) { /* it hasn't */ |
124 | if (!recv_length) { | 124 | if (!recv_length) { |
125 | strcpy (recv_buffer, ""); | 125 | strcpy (recv_buffer, ""); |
126 | printf ("No data was received from host!\n"); | 126 | printf (_("No data was received from host!\n")); |
127 | result = STATE_WARNING; | 127 | result = STATE_WARNING; |
128 | } | 128 | } |
129 | else { /* this one failed, but previous ones worked */ | 129 | else { /* this one failed, but previous ones worked */ |
@@ -239,7 +239,7 @@ my_connect (const char *host_name, int port, int *sd, int proto) | |||
239 | SOCK_DGRAM : SOCK_STREAM, res->ai_protocol); | 239 | SOCK_DGRAM : SOCK_STREAM, res->ai_protocol); |
240 | 240 | ||
241 | if (*sd < 0) { | 241 | if (*sd < 0) { |
242 | printf ("Socket creation failed\n"); | 242 | printf (_("Socket creation failed\n")); |
243 | freeaddrinfo (res); | 243 | freeaddrinfo (res); |
244 | return STATE_UNKNOWN; | 244 | return STATE_UNKNOWN; |
245 | } | 245 | } |
@@ -315,7 +315,7 @@ send_request (int sd, int proto, const char *send_buffer, char *recv_buffer, int | |||
315 | 315 | ||
316 | send_result = send (sd, send_buffer, strlen (send_buffer), 0); | 316 | send_result = send (sd, send_buffer, strlen (send_buffer), 0); |
317 | if (send_result<0 || (size_t)send_result!=strlen(send_buffer)) { | 317 | if (send_result<0 || (size_t)send_result!=strlen(send_buffer)) { |
318 | printf ("Send failed\n"); | 318 | printf (_("Send failed\n")); |
319 | result = STATE_WARNING; | 319 | result = STATE_WARNING; |
320 | } | 320 | } |
321 | 321 | ||
@@ -330,7 +330,7 @@ send_request (int sd, int proto, const char *send_buffer, char *recv_buffer, int | |||
330 | /* make sure some data has arrived */ | 330 | /* make sure some data has arrived */ |
331 | if (!FD_ISSET (sd, &readfds)) { | 331 | if (!FD_ISSET (sd, &readfds)) { |
332 | strcpy (recv_buffer, ""); | 332 | strcpy (recv_buffer, ""); |
333 | printf ("No data was received from host!\n"); | 333 | printf (_("No data was received from host!\n")); |
334 | result = STATE_WARNING; | 334 | result = STATE_WARNING; |
335 | } | 335 | } |
336 | 336 | ||
@@ -339,7 +339,7 @@ send_request (int sd, int proto, const char *send_buffer, char *recv_buffer, int | |||
339 | if (recv_result == -1) { | 339 | if (recv_result == -1) { |
340 | strcpy (recv_buffer, ""); | 340 | strcpy (recv_buffer, ""); |
341 | if (proto != IPPROTO_TCP) | 341 | if (proto != IPPROTO_TCP) |
342 | printf ("Receive failed\n"); | 342 | printf (_("Receive failed\n")); |
343 | result = STATE_WARNING; | 343 | result = STATE_WARNING; |
344 | } | 344 | } |
345 | else | 345 | else |