proc: Add process state T

On linux kernel 2.6.x, the Trace/Stop status is 'T'

Fixes #209
This commit is contained in:
Joe Grasse 2016-03-11 09:55:10 -06:00 committed by Derek Parker
parent 7d3d90a04d
commit 59ef8a7a71
2 changed files with 4 additions and 1 deletions

@ -27,6 +27,9 @@ const (
StatusRunning = 'R' StatusRunning = 'R'
StatusTraceStop = 't' StatusTraceStop = 't'
StatusZombie = 'Z' StatusZombie = 'Z'
// Kernel 2.6 has TraceStop as T
StatusTraceStopT = 'T'
) )
// OSProcessDetails contains Linux specific // OSProcessDetails contains Linux specific

@ -30,7 +30,7 @@ func (t *Thread) halt() (err error) {
func (t *Thread) stopped() bool { func (t *Thread) stopped() bool {
state := status(t.ID, t.dbp.os.comm) state := status(t.ID, t.dbp.os.comm)
return state == StatusTraceStop return state == StatusTraceStop || state == StatusTraceStopT
} }
func (t *Thread) resume() error { func (t *Thread) resume() error {