From nobody Tue Dec 10 02:40:41 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4Y6jdk2647z5h82f; Tue, 10 Dec 2024 02:40:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Y6jdj6lP3z4mpk; Tue, 10 Dec 2024 02:40:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733798441; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=mjSFIptpj7OQZawgeZ8J5Vr8+D/G7Z4GvKJa2otwEnQ=; b=os63BxvdRF9pl1OnehXc2MnBnvFFQ2LA2YiOodQNNOE5bXPy8TJSepERDPf4J6KmQYOBaK a2L6DYTKIH89C+Oz0gJb29KfMx8xw2VuPHTqORld4mXYnXTzBXYLscxd4WSUnPvc9T3h17 Lw5vw9ZzZ8xC7tGowurSZ+86tw4isERrbyYyBYrdTXrewcH11S7Xs+adfpww/NkJa4WzvU 2VPuVlzsF+PmmzINmMjsZI6qO0WSwhCNXYvWqciFKkaCWw6Y48vcdK/ONioiSLzrvrc1Yf dwc5sJcnEESYUM4nDrGBx7jqqogJ+bNkhuPObqoEl6c+PfKmbxmbS9e/7arBLQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733798441; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=mjSFIptpj7OQZawgeZ8J5Vr8+D/G7Z4GvKJa2otwEnQ=; b=jZ6xOPVNi0YQ02TUEbpNKNV29dwL6a4VJNKagvviqcNLXuoRgLBuyiAUSRLUJO1ZVVdkiG MmrsRUtuGt14btMWgXSS5SwJVPPe6g3gn+Y6wBDriRQyPhXGsxlNxarMpS4004cwy8Akum O9yDZVG02IllA8vzAReTF+IpUNCZeQ2Wrekoy7ERbfSs/dFGyt/oDqobr+rUmH7FkeWf6G QUZ5N1bVJiLPuRFvLR4KlGWDOssVKNSgnUdmiKw89jgJPlGhqtMkxMtA6aY0rI3LrtBZv+ hiTDd8BUCWAWmhIecE2NNqTmmzo5lfSGEEaxErQeNYtKbFZElo7GPtbWTX7BzQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733798441; a=rsa-sha256; cv=none; b=W6dhDOb5uJX/TMHrAW4sPtbHveNcMYffRsuPkuoKiX3QGpMvKZYaF6FdhuKjkEaCtoxAl8 s3bSYAGx6Lqt1jBiiy+xhJK/A8b9mGhKJ54WYJXyAkWAtL7KOTNWUuobLg8OBLOXoo0EM3 OSAEiHJ9PegClNYUshMiNIvqD9AZMPtayExFfu0apikur10pzQEzhcs/DqhwtXYzHGFPxK HYY2rXslIyp6IrRC9hI/rNxWuaOZ6O61KQpvyho5Q/bkCEfzS5pCx4pe/zAjKJqU2QBjDu jEOjrvkazQYhAxs9RUb/QIRy7vLMF627yNN/Jvy5rxhu7sRiCf98MsSMDl+wRw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4Y6jdj6Mp3z14G3; Tue, 10 Dec 2024 02:40:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 4BA2efIX083450; Tue, 10 Dec 2024 02:40:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BA2efVp083447; Tue, 10 Dec 2024 02:40:41 GMT (envelope-from git) Date: Tue, 10 Dec 2024 02:40:41 GMT Message-Id: <202412100240.4BA2efVp083447@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: b50851e8ebfa - stable/14 - prison_proc_iterate(): make it work for prison0 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: b50851e8ebfa8acc77607a4ff1095ed6e4a56881 Auto-Submitted: auto-generated The branch stable/14 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=b50851e8ebfa8acc77607a4ff1095ed6e4a56881 commit b50851e8ebfa8acc77607a4ff1095ed6e4a56881 Author: Konstantin Belousov AuthorDate: 2024-12-06 17:01:00 +0000 Commit: Konstantin Belousov CommitDate: 2024-12-10 02:40:24 +0000 prison_proc_iterate(): make it work for prison0 PR: 283163 (cherry picked from commit 831531a82e0f1d1d7b97e50c0587639322ed8d2e) --- sys/kern/kern_jail.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sys/kern/kern_jail.c b/sys/kern/kern_jail.c index a4bd27734e8e..c4e89774f18b 100644 --- a/sys/kern/kern_jail.c +++ b/sys/kern/kern_jail.c @@ -3051,8 +3051,7 @@ prison_proc_iterate(struct prison *pr, void (*cb)(struct proc *, void *), FOREACH_PROC_IN_SYSTEM(p) { PROC_LOCK(p); if (p->p_state != PRS_NEW && p->p_ucred != NULL) { - for (ppr = p->p_ucred->cr_prison; - ppr != &prison0; + for (ppr = p->p_ucred->cr_prison; ppr != NULL; ppr = ppr->pr_parent) { if (ppr == pr) { cb(p, cbarg);