Date: Wed, 4 Jul 2018 13:28:16 +0000 (UTC) From: Konstantin Belousov <kib@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r335937 - head/usr.bin/top Message-ID: <201807041328.w64DSGxa002871@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: kib Date: Wed Jul 4 13:28:16 2018 New Revision: 335937 URL: https://svnweb.freebsd.org/changeset/base/335937 Log: top: do not fall to the thread name if kernel cache of the process args is empty. Instead, use kvm_getargv() unconditionally to obtain the process arguments. It means that one additional sysctl(2) is performed there. Submitted by: Thomas Munro MFC after: 1 week Differential revision: https://reviews.freebsd.org/D16111 Modified: head/usr.bin/top/machine.c Modified: head/usr.bin/top/machine.c ============================================================================== --- head/usr.bin/top/machine.c Wed Jul 4 13:26:47 2018 (r335936) +++ head/usr.bin/top/machine.c Wed Jul 4 13:28:16 2018 (r335937) @@ -951,7 +951,6 @@ format_next_process(struct handle * xhandle, char *(*g } } else { if (pp->ki_flag & P_SYSTEM || - pp->ki_args == NULL || (args = kvm_getargv(kd, pp, cmdlen)) == NULL || !(*args)) { if (ps.thread && pp->ki_flag & P_HADTHREADS &&
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201807041328.w64DSGxa002871>