From 1ebe625e5aa21b33e9de5652c305d1d0a2147059 Mon Sep 17 00:00:00 2001 From: wiggin15 Date: Tue, 26 Sep 2017 14:52:42 +0300 Subject: AIX support (#1123) * AIX support * AIX support * AIX support * AIX support - use get_procfs_path() instead of /proc * AIX support - group sections like in other modules * AIX support * AIX support * AIX support * AIX support - remove unnecessary dict copy --- scripts/procinfo.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'scripts/procinfo.py') diff --git a/scripts/procinfo.py b/scripts/procinfo.py index d8625560..54205de3 100755 --- a/scripts/procinfo.py +++ b/scripts/procinfo.py @@ -225,7 +225,8 @@ def run(pid, verbose=False): if 'io_counters' in pinfo: print_('I/O', str_ntuple(pinfo['io_counters'], bytes2human=True)) - print_("ctx-switches", str_ntuple(pinfo['num_ctx_switches'])) + if 'num_ctx_switches' in pinfo: + print_("ctx-switches", str_ntuple(pinfo['num_ctx_switches'])) if pinfo['children']: template = "%-6s %s" print_("children", template % ("PID", "NAME")) -- cgit v1.2.1