Bug 908296 - Upgrade psutil to version 1.0.1; rs=glandium
Archive obtained from https://psutil.googlecode.com/files/psutil-1.0.1.tar.gz and extracted over existing source code without modifications.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
#!/usr/bin/env python
|
||||
|
||||
# Copyright (c) 2009, Jay Loden, Giampaolo Rodola'. All rights reserved.
|
||||
# Copyright (c) 2009, Giampaolo Rodola'. All rights reserved.
|
||||
# Use of this source code is governed by a BSD-style license that can be
|
||||
# found in the LICENSE file.
|
||||
|
||||
@@ -167,8 +167,12 @@ def refresh_window(procs, procs_status):
|
||||
p.dict['memory_percent'] = ''
|
||||
if p.dict['cpu_percent'] is None:
|
||||
p.dict['cpu_percent'] = ''
|
||||
if p.dict['username']:
|
||||
username = p.dict['username'][:8]
|
||||
else:
|
||||
username = ""
|
||||
line = templ % (p.pid,
|
||||
p.dict['username'][:8],
|
||||
username,
|
||||
p.dict['nice'],
|
||||
bytes2human(getattr(p.dict['memory_info'], 'vms', 0)),
|
||||
bytes2human(getattr(p.dict['memory_info'], 'rss', 0)),
|
||||
|
||||
Reference in New Issue
Block a user