2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2025-06-24 15:05:36 +00:00

modified depending on comments

This commit is contained in:
XuWei
2016-11-08 02:32:01 -05:00
parent 74dca9c43e
commit 409e32bd70

View File

@ -343,11 +343,9 @@ sub dump_mac_info {
}
elsif (defined($self->{macinfo}->{$switch}->{ErrorStr})) {
$ret{$switch}->{ErrorStr} = $self->{macinfo}->{$switch}->{ErrorStr};
if ($ret{$switch}->{ErrorStr} =~ /Unknown user name/) {
$ret{$switch}->{ErrorStr} = "Unknown snmp user name";
}
# To show the error message that the username/password related error is for SNMP only
if ($ret{$switch}->{ErrorStr} =~ /username|password/i) {
if ($ret{$switch}->{ErrorStr} =~ /user\s*name|password/i) {
$ret{$switch}->{ErrorStr} .= " through SNMP";
}
} else {