From 9bba73fa6d1ece54147850183a9841c6568a1106 Mon Sep 17 00:00:00 2001 From: Paul Townsend Date: Mon, 5 Dec 2011 22:42:38 -0600 Subject: [PATCH] Count only filtered pids If '-t' is specified and a filter such as '-U me' is specified, the pid total displayed is the total number of pids instead of the number of filtered pids. --- smem | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/smem b/smem index bbf6775..1509954 100755 --- a/smem +++ b/smem @@ -269,7 +269,7 @@ def showpids(): return pidusername(p) fields = dict( - pid=('PID', lambda n: n, '% 5s', lambda x: len(p), + pid=('PID', lambda n: n, '% 5s', lambda x: len(pt), 'process ID'), user=('User', showuser, '%-8s', lambda x: len(dict.fromkeys(x)), 'owner of process'),