Changeset 3867

Show
Ignore:
Timestamp:
08/19/10 11:19:21 (1 year ago)
Author:
mha
Message:

Properly return undef when the SNMP client returns noSuchObject instead
of setting an error.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/plugins/lib/Munin/Plugin/SNMP.pm

    r3563 r3867  
    477477        my $response = $handle->get_request($oid); 
    478478 
    479         if (!defined $response->{$oid} or $handle->error_status) { 
     479        if (!defined $response->{$oid} or $handle->error_status or $response->{$oid} eq 'noSuchObject') { 
    480480            print STDERR "# Error getting $oid: ",$handle->error(),"\n" 
    481481                if $DEBUG;