Skip to content

Commit

Permalink
fix(inputs.cisco_telemetry_mdt): Check for slice length
Browse files Browse the repository at this point in the history
fixes: #13789
  • Loading branch information
powersj committed Aug 22, 2023
1 parent 3f206f6 commit 7d4190d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions plugins/inputs/cisco_telemetry_mdt/cisco_telemetry_mdt.go
Original file line number Diff line number Diff line change
Expand Up @@ -416,6 +416,10 @@ func (c *CiscoTelemetryMDT) handleTelemetry(data []byte) {
if content != nil {
// Parse values
for _, subfield := range content.Fields {
if len(subfield.Fields) == 0 {
continue
}

prefix := ""
switch subfield.Name {
case "operation-metric":
Expand Down

0 comments on commit 7d4190d

Please sign in to comment.