There was an error while loading. Please reload this page.
1 parent 433c6d5 commit 4d39083Copy full SHA for 4d39083
1 file changed
net/net_aix.go
@@ -52,7 +52,7 @@ func parseNetstatS(output string, protocols []string) ([]ProtoCountersStat, erro
52
sections := make(map[string][]string)
53
var currentProto string
54
for _, line := range strings.Split(output, "\n") {
55
- if len(line) > 0 && line[0] != '\t' && line[0] != ' ' && strings.HasSuffix(strings.TrimSpace(line), ":") {
+ if line != "" && line[0] != '\t' && line[0] != ' ' && strings.HasSuffix(strings.TrimSpace(line), ":") {
56
currentProto = strings.TrimSuffix(strings.TrimSpace(line), ":")
57
continue
58
}
0 commit comments