Date: Sat, 26 Jul 2025 17:12:43 GMT From: Warner Losh <imp@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: git: ea60d917e5b1 - main - linprocfs: Continue on error when reading process limits Message-ID: <202507261712.56QHCh0D082704@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=ea60d917e5b1943c8638af056dbcdbb3646207f1 commit ea60d917e5b1943c8638af056dbcdbb3646207f1 Author: Ricardo Branco <rbranco@suse.de> AuthorDate: 2025-02-06 21:46:19 +0000 Commit: Warner Losh <imp@FreeBSD.org> CommitDate: 2025-07-26 17:12:38 +0000 linprocfs: Continue on error when reading process limits The process limits may be unavailable due to capsicum. Like other areas of the system, report what we can w/o error. This is what Linux does. PR: 283726 Reviewed by: imp, dchagin Pull Request: https://github.com/freebsd/freebsd-src/pull/1592 --- sys/compat/linprocfs/linprocfs.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/sys/compat/linprocfs/linprocfs.c b/sys/compat/linprocfs/linprocfs.c index cfb054235489..1c6d64d6b8bc 100644 --- a/sys/compat/linprocfs/linprocfs.c +++ b/sys/compat/linprocfs/linprocfs.c @@ -1911,7 +1911,7 @@ linprocfs_doproclimits(PFS_FILL_ARGS) "kern.sigqueue.max_pending_per_proc", &res, &size, 0, 0, 0, 0); if (error != 0) - goto out; + continue; rl.rlim_cur = res; rl.rlim_max = res; break; @@ -1919,7 +1919,7 @@ linprocfs_doproclimits(PFS_FILL_ARGS) error = kernel_sysctlbyname(td, "kern.ipc.msgmnb", &res, &size, 0, 0, 0, 0); if (error != 0) - goto out; + continue; rl.rlim_cur = res; rl.rlim_max = res; break; @@ -1941,9 +1941,9 @@ linprocfs_doproclimits(PFS_FILL_ARGS) li->desc, (unsigned long long)rl.rlim_cur, (unsigned long long)rl.rlim_max, li->unit); } -out: + lim_free(limp); - return (error); + return (0); } /*
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202507261712.56QHCh0D082704>