Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 9 Dec 2021 00:24:08 GMT
From:      Konstantin Belousov <kib@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org
Subject:   git: ed43c7ac0a8c - stable/13 - procstat_getfiles_sysctl: do not require non-null ki_fd
Message-ID:  <202112090024.1B90O8hh064271@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch stable/13 has been updated by kib:

URL: https://cgit.FreeBSD.org/src/commit/?id=ed43c7ac0a8c29510a42b56f79a7db32855e9821

commit ed43c7ac0a8c29510a42b56f79a7db32855e9821
Author:     Konstantin Belousov <kib@FreeBSD.org>
AuthorDate: 2021-12-02 18:03:01 +0000
Commit:     Konstantin Belousov <kib@FreeBSD.org>
CommitDate: 2021-12-09 00:23:29 +0000

    procstat_getfiles_sysctl: do not require non-null ki_fd
    
    PR:     260174
    
    (cherry picked from commit 7a9423d6f360e3758ca67fbb25d309140ea93670)
---
 lib/libprocstat/libprocstat.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/lib/libprocstat/libprocstat.c b/lib/libprocstat/libprocstat.c
index 176c2b7f8c6f..89896a813888 100644
--- a/lib/libprocstat/libprocstat.c
+++ b/lib/libprocstat/libprocstat.c
@@ -868,8 +868,6 @@ procstat_getfiles_sysctl(struct procstat *procstat, struct kinfo_proc *kp,
 	cap_rights_t cap_rights;
 
 	assert(kp);
-	if (kp->ki_fd == NULL)
-		return (NULL);
 	switch (procstat->type) {
 	case PROCSTAT_SYSCTL:
 		files = kinfo_getfile(kp->ki_pid, &cnt);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202112090024.1B90O8hh064271>