+ correct compiling error

This commit is contained in:
garnier-quentin 2017-01-17 10:42:30 +01:00
parent e4c04980ac
commit 8b83baf872

View File

@ -147,8 +147,8 @@ sub send_trap_netsnmp {
}
my $args = [];
push @$args, ('1.3.6.1.2.1.1.3.0', Net::SNMP::TIMETICKS, time());
push @$args, ('1.3.6.1.6.3.1.1.4.1.0', Net::SNMP::OBJECT_IDENTIFIER, $self->{option_results}->{oid_trap});
push @$args, ('1.3.6.1.2.1.1.3.0', eval "Net::SNMP::TIMETICKS", time());
push @$args, ('1.3.6.1.6.3.1.1.4.1.0', eval "Net::SNMP::OBJECT_IDENTIFIER", $self->{option_results}->{oid_trap});
foreach (('hostname', 'start', 'end', 'author', 'comment', 'duration')) {
my $type = $self->{snmp_args}->{$_}->{type};
$type = 'OCTET_STRING' if ($type eq 'OCTETSTR');