Skip to content

Commit

Permalink
Fix for loop over value array range issue. (#2187)
Browse files Browse the repository at this point in the history
  • Loading branch information
wolfeidau authored and sparrc committed Dec 20, 2016
1 parent 8311ff9 commit 2f521a8
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion plugins/inputs/system/ps.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,10 @@ func (s *systemPS) DiskUsage(
var usage []*disk.UsageStat
var partitions []*disk.PartitionStat

for _, p := range parts {
for i := range parts {

p := parts[i]

if len(mountPointFilter) > 0 {
// If the mount point is not a member of the filter set,
// don't gather info on it.
Expand Down

0 comments on commit 2f521a8

Please sign in to comment.