1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

Merge pull request #16389 from HuKeping/stats-zero

Reset data of stats in docker cli when container stopped
This commit is contained in:
Antonio Murdaca 2015-09-18 18:59:51 +02:00
commit 41646cb4e3

View file

@ -99,6 +99,11 @@ func (s *containerStats) Collect(cli *DockerCli, streamStats bool) {
s.CPUPercentage = 0 s.CPUPercentage = 0
s.Memory = 0 s.Memory = 0
s.MemoryPercentage = 0 s.MemoryPercentage = 0
s.MemoryLimit = 0
s.NetworkRx = 0
s.NetworkTx = 0
s.BlockRead = 0
s.BlockWrite = 0
s.mu.Unlock() s.mu.Unlock()
case err := <-u: case err := <-u:
if err != nil { if err != nil {