Commit Graph

8 Commits

Author SHA1 Message Date
Antoine Toulme b712e59295 fix more linting reports 2023-06-03 14:17:16 -07:00
mmorel-35 1e6b445a8a gofumpt 2021-12-22 21:54:41 +00:00
Shirou WAKAYAMA 97e1d05084 [docker]linux: add CgroupDockerStat (#189) 2016-04-24 17:15:45 +09:00
Shirou WAKAYAMA 40bbba9636 docker[linux]: add more memory stats in cgroup. 2015-11-21 23:00:37 +09:00
Jason Wilder 90c6c3ef3e Fix panic in CgroupCPU
If an invalid container ID is passed to CgroupCPU,
a panic can result.
2015-02-10 11:36:19 -07:00
Jason Wilder 812b04d363 Don't ignore err when getting CgroupMemDocker stats
Fixes panic: runtime error: index out of range

goroutine 10 [running]:
testing.func·006()
	/usr/local/go/src/testing/testing.go:441 +0x181
github.com/shirou/gopsutil/docker.CgroupMem(0x586b30, 0x6, 0x5a87d0, 0x1c, 0x0, 0x0, 0x0)
	/home/jwilder/go/src/github.com/shirou/gopsutil/docker/docker_linux.go:119 +0xf48
github.com/shirou/gopsutil/docker.CgroupMemDocker(0x586b30, 0x6, 0x0, 0x0, 0x0)
	/home/jwilder/go/src/github.com/shirou/gopsutil/docker/docker_linux.go:184 +0x57

If the ID passed to the CGroupMemDocker does not exist, you can get
a panic at runtime.  This can happen when a container exits before
calling the func.
2015-02-10 11:32:40 -07:00
Shirou WAKAYAMA 13cd195a7e change package name. 2014-12-30 22:09:05 +09:00
Shirou WAKAYAMA a4671fcc2a move subdirectories. refer to issue #24 2014-11-27 10:18:15 +09:00