Show
Ignore:
Timestamp:
05/06/10 03:42:28 (4 years ago)
Author:
Jason Dixon <jdixon@omniti.com>
git-committer:
Jason Dixon <jdixon@omniti.com> 1273117348 +0000
git-parent:

[9b3ba7bdbc8d3a7d32b3a0b1507354a690562b94]

git-author:
Jason Dixon <jdixon@omniti.com> 1273117348 +0000
Message:

only save on a match

git-svn-id: https://labs.omniti.com/resmon/branches/resmon2@355 8c0face9-b7db-6ec6-c4b3-d5f7145c7d55

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • lib/Core/Pf/Queues.pm

    r9b3ba7b rd5d97a4  
    6868        foreach (split(/queue\s+/, $output)) { 
    6969            next unless /\w+/; 
    70             /(\S+)\s+.*\n\s+\[\s+pkts\:\s+(\d+)\s+bytes\:\s+(\d+)\s+dropped\s+pkts\:\s+(\d+)\s+bytes\:\s+(\d+).*/; 
    71             $metrics{"${1}_pkts"} = [$2, 'i'], 
    72             $metrics{"${1}_bytes"} = [$3, 'i'], 
    73             $metrics{"${1}_drop_pkts"} = [$4, 'i'], 
    74             $metrics{"${1}_drop_bytes"} = [$5, 'i'], 
     70            if (/(\S+)\s+.*\n\s+\[\s+pkts\:\s+(\d+)\s+bytes\:\s+(\d+)\s+dropped\s+pkts\:\s+(\d+)\s+bytes\:\s+(\d+).*/) { 
     71                $metrics{"${1}_pkts"} = [$2, 'i'], 
     72                $metrics{"${1}_bytes"} = [$3, 'i'], 
     73                $metrics{"${1}_drop_pkts"} = [$4, 'i'], 
     74                $metrics{"${1}_drop_bytes"} = [$5, 'i'], 
     75            } 
    7576        } 
    7677    } else {