提交 7bbbbff1 编写于 作者: N Nicolas Hennion

Merge pull request #337 from regdoug/windows-psutil-0.5

Fixed psutil 0.5.x support on Windows
......@@ -1632,8 +1632,12 @@ class GlancesStats:
phymem = psutil.phymem_usage()
# buffers and cached (Linux, BSD)
buffers = getattr(psutil, 'phymem_buffers', 0)()
cached = getattr(psutil, 'cached_phymem', 0)()
try:
buffers = getattr(psutil, 'phymem_buffers', 0)()
cached = getattr(psutil, 'cached_phymem', 0)()
except TypeError:
buffers = 0
cached = 0
# phymem free and usage
total = phymem.total
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册