We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 978af3b commit 624e205Copy full SHA for 624e205
inspector/docker_stats.go
@@ -32,8 +32,15 @@ type DockerStats struct {
32
// Parse : run custom parsing on output of the command
33
func (i *DockerStats) Parse(output string) {
34
var values []DockerStatsMetrics
35
+ var splitChars string
36
+ details := (*i.Driver).GetDetails()
37
+ if details.IsWindows {
38
+ splitChars = "\r\n"
39
+ } else {
40
+ splitChars = "\n"
41
+ }
42
log.Debug("Parsing ouput string in DockerStats inspector")
- lines := strings.Split(output, "\n")
43
+ lines := strings.Split(output, splitChars)
44
for index, line := range lines {
45
// skip title line
46
if index == 0 {
0 commit comments