Merge branch 'master' into feature_check_curl

This commit is contained in:
Andreas Baumann 2021-07-28 19:17:46 +02:00
commit 67088216ab
3 changed files with 3 additions and 5 deletions

View file

@ -124,10 +124,10 @@ if (!defined($session)) {
## map ifdescr to ifindex - should look at being able to cache this value
if (defined $ifdescr || defined $iftype) {
# escape "/" in ifdescr - very common in the Cisco world
if (defined $iftype) {
$status=fetch_ifindex($snmpIfType, $iftype);
} else {
# escape "/" in ifdescr - very common in the Cisco world
$ifdescr =~ s/\//\\\//g;
$status=fetch_ifindex($snmpIfDescr, $ifdescr); # if using on device with large number of interfaces
# recommend use of SNMP v2 (get-bulk)

View file

@ -230,7 +230,6 @@ process_arguments (int argc, char **argv)
timeout_interval = atoi (optarg);
break;
case 'H': /* host */
host_or_die(optarg);
hostname = optarg;
break;
case 'p': /* port number */
@ -329,7 +328,6 @@ process_arguments (int argc, char **argv)
if (c <= argc) {
die (STATE_UNKNOWN, _("%s: You must provide a host name\n"), progname);
}
host_or_die(argv[c]);
hostname = argv[c++];
}

View file

@ -1453,8 +1453,8 @@ redir (char *pos, char *status_line)
!strncmp(server_address, addr, MAX_IPV4_HOSTLENGTH) &&
(host_name && !strncmp(host_name, addr, MAX_IPV4_HOSTLENGTH)) &&
!strcmp(server_url, url))
die (STATE_WARNING,
_("HTTP WARNING - redirection creates an infinite loop - %s://%s:%d%s%s\n"),
die (STATE_CRITICAL,
_("HTTP CRITICAL - redirection creates an infinite loop - %s://%s:%d%s%s\n"),
type, addr, i, url, (display_html ? "</A>" : ""));
strcpy (server_type, type);