ENH use faster pid comm lookup method
This commit is contained in:
parent
b9a140d445
commit
0e54fd1eda
|
@ -228,7 +228,7 @@ local update = function(cr)
|
|||
local pid = conky(TABLE_CONKY[r].pid, '(%S+)')
|
||||
if pid ~= '' then
|
||||
local cpu = conky(TABLE_CONKY[r].cpu)
|
||||
local comm = Util.read_file('/proc/'..pid..'/stat', '%d+%s+%((.+)%)')
|
||||
local comm = Util.read_file('/proc/'..pid..'/comm')
|
||||
Table.set(tbl, cr, 1, r, comm)
|
||||
Table.set(tbl, cr, 2, r, pid)
|
||||
Table.set(tbl, cr, 3, r, cpu)
|
||||
|
|
Loading…
Reference in New Issue