summaryrefslogtreecommitdiffhomepage
path: root/pkg/sentry/control
diff options
context:
space:
mode:
authorgVisor bot <gvisor-bot@google.com>2021-02-24 11:47:27 -0800
committergVisor bot <gvisor-bot@google.com>2021-02-24 11:47:27 -0800
commit8f6274404a87aa6adb2c8f322b9ee7aae2589fba (patch)
tree817907f6d65ecbf124a4ee58231567f1ca2ba3bd /pkg/sentry/control
parent055073f11813a7b675cb19aa6c540a667cd746a5 (diff)
parent306a9477daa7b57ef62133bcf3f2f5966e26ffca (diff)
Merge pull request #5519 from dqminh:runsc-ps-pids
PiperOrigin-RevId: 359334029
Diffstat (limited to 'pkg/sentry/control')
-rw-r--r--pkg/sentry/control/proc.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/pkg/sentry/control/proc.go b/pkg/sentry/control/proc.go
index f93bd64e0..367849e75 100644
--- a/pkg/sentry/control/proc.go
+++ b/pkg/sentry/control/proc.go
@@ -334,8 +334,8 @@ func PrintPIDsJSON(pl []*Process) (string, error) {
func Processes(k *kernel.Kernel, containerID string, out *[]*Process) error {
ts := k.TaskSet()
now := k.RealtimeClock().Now()
- for _, tg := range ts.Root.ThreadGroups() {
- pidns := tg.PIDNamespace()
+ pidns := ts.Root
+ for _, tg := range pidns.ThreadGroups() {
pid := pidns.IDOfThreadGroup(tg)
// If tg has already been reaped ignore it.