diff options
Diffstat (limited to 'plugins')
| -rw-r--r-- | plugins/check_ping.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/plugins/check_ping.c b/plugins/check_ping.c index 23dcd6a8..473f9f24 100644 --- a/plugins/check_ping.c +++ b/plugins/check_ping.c | |||
| @@ -516,32 +516,32 @@ error_scan (char buf[MAX_INPUT_BUFFER], const char *addr) | |||
| 516 | if (strstr (buf, "Network is unreachable") || | 516 | if (strstr (buf, "Network is unreachable") || |
| 517 | strstr (buf, "Destination Net Unreachable") | 517 | strstr (buf, "Destination Net Unreachable") |
| 518 | ) | 518 | ) |
| 519 | die (STATE_CRITICAL, _("CRITICAL - Network Unreachable (%s)"), addr); | 519 | die (STATE_CRITICAL, _("CRITICAL - Network Unreachable (%s)\n"), addr); |
| 520 | else if (strstr (buf, "Destination Host Unreachable")) | 520 | else if (strstr (buf, "Destination Host Unreachable")) |
| 521 | die (STATE_CRITICAL, _("CRITICAL - Host Unreachable (%s)"), addr); | 521 | die (STATE_CRITICAL, _("CRITICAL - Host Unreachable (%s)\n"), addr); |
| 522 | else if (strstr (buf, "Destination Port Unreachable")) | 522 | else if (strstr (buf, "Destination Port Unreachable")) |
| 523 | die (STATE_CRITICAL, _("CRITICAL - Bogus ICMP: Port Unreachable (%s)"), addr); | 523 | die (STATE_CRITICAL, _("CRITICAL - Bogus ICMP: Port Unreachable (%s)\n"), addr); |
| 524 | else if (strstr (buf, "Destination Protocol Unreachable")) | 524 | else if (strstr (buf, "Destination Protocol Unreachable")) |
| 525 | die (STATE_CRITICAL, _("CRITICAL - Bogus ICMP: Protocol Unreachable (%s)"), addr); | 525 | die (STATE_CRITICAL, _("CRITICAL - Bogus ICMP: Protocol Unreachable (%s)\n"), addr); |
| 526 | else if (strstr (buf, "Destination Net Prohibited")) | 526 | else if (strstr (buf, "Destination Net Prohibited")) |
| 527 | die (STATE_CRITICAL, _("CRITICAL - Network Prohibited (%s)"), addr); | 527 | die (STATE_CRITICAL, _("CRITICAL - Network Prohibited (%s)\n"), addr); |
| 528 | else if (strstr (buf, "Destination Host Prohibited")) | 528 | else if (strstr (buf, "Destination Host Prohibited")) |
| 529 | die (STATE_CRITICAL, _("CRITICAL - Host Prohibited (%s)"), addr); | 529 | die (STATE_CRITICAL, _("CRITICAL - Host Prohibited (%s)\n"), addr); |
| 530 | else if (strstr (buf, "Packet filtered")) | 530 | else if (strstr (buf, "Packet filtered")) |
| 531 | die (STATE_CRITICAL, _("CRITICAL - Packet Filtered (%s)"), addr); | 531 | die (STATE_CRITICAL, _("CRITICAL - Packet Filtered (%s)\n"), addr); |
| 532 | else if (strstr (buf, "unknown host" )) | 532 | else if (strstr (buf, "unknown host" )) |
| 533 | die (STATE_CRITICAL, _("CRITICAL - Host not found (%s)"), addr); | 533 | die (STATE_CRITICAL, _("CRITICAL - Host not found (%s)\n"), addr); |
| 534 | else if (strstr (buf, "Time to live exceeded")) | 534 | else if (strstr (buf, "Time to live exceeded")) |
| 535 | die (STATE_CRITICAL, _("CRITICAL - Time to live exceeded (%s)"), addr); | 535 | die (STATE_CRITICAL, _("CRITICAL - Time to live exceeded (%s)\n"), addr); |
| 536 | else if (strstr (buf, "Destination unreachable: ")) | 536 | else if (strstr (buf, "Destination unreachable: ")) |
| 537 | die (STATE_CRITICAL, _("CRITICAL - Destination Unreachable (%s)"), addr); | 537 | die (STATE_CRITICAL, _("CRITICAL - Destination Unreachable (%s)\n"), addr); |
| 538 | 538 | ||
| 539 | if (strstr (buf, "(DUP!)") || strstr (buf, "DUPLICATES FOUND")) { | 539 | if (strstr (buf, "(DUP!)") || strstr (buf, "DUPLICATES FOUND")) { |
| 540 | if (warn_text == NULL) | 540 | if (warn_text == NULL) |
| 541 | warn_text = strdup (_(WARN_DUPLICATES)); | 541 | warn_text = strdup (_(WARN_DUPLICATES)); |
| 542 | else if (! strstr (warn_text, _(WARN_DUPLICATES)) && | 542 | else if (! strstr (warn_text, _(WARN_DUPLICATES)) && |
| 543 | asprintf (&warn_text, "%s %s", warn_text, _(WARN_DUPLICATES)) == -1) | 543 | asprintf (&warn_text, "%s %s", warn_text, _(WARN_DUPLICATES)) == -1) |
| 544 | die (STATE_UNKNOWN, _("Unable to realloc warn_text")); | 544 | die (STATE_UNKNOWN, _("Unable to realloc warn_text\n")); |
| 545 | return (STATE_WARNING); | 545 | return (STATE_WARNING); |
| 546 | } | 546 | } |
| 547 | 547 | ||
