From owner-cvs-src-old@FreeBSD.ORG Mon Jul 18 21:16:21 2011 Return-Path: Delivered-To: cvs-src-old@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CDDE8106567C for ; Mon, 18 Jul 2011 21:16:21 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id BC9958FC19 for ; Mon, 18 Jul 2011 21:16:21 +0000 (UTC) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.4/8.14.4) with ESMTP id p6ILGLnR002925 for ; Mon, 18 Jul 2011 21:16:21 GMT (envelope-from jhb@repoman.freebsd.org) Received: (from svn2cvs@localhost) by repoman.freebsd.org (8.14.4/8.14.4/Submit) id p6ILGLMr002924 for cvs-src-old@freebsd.org; Mon, 18 Jul 2011 21:16:21 GMT (envelope-from jhb@repoman.freebsd.org) Message-Id: <201107182116.p6ILGLMr002924@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: svn2cvs set sender to jhb@repoman.freebsd.org using -f From: John Baldwin Date: Mon, 18 Jul 2011 21:15:47 +0000 (UTC) To: cvs-src-old@freebsd.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/contrib/top display.c top.c src/usr.bin/top machine.c X-BeenThere: cvs-src-old@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: **OBSOLETE** CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 18 Jul 2011 21:16:21 -0000 jhb 2011-07-18 21:15:47 UTC FreeBSD src repository Modified files: contrib/top display.c top.c usr.bin/top machine.c Log: SVN rev 224205 on 2011-07-18 21:15:47Z by jhb Rework the dynamic per-CPU stats code a bit. Always set 'statics->ncpus' to the maximum number of CPUs to ensure that lcpustates[] array is always allocated to the maximum size. Previously, if top was started without per-CPU stats it would allocate a smaller lcpustates[] array. When per-CPU stats were then enabled, it would overflow the array and trash the cpustates_columns[] array causing the CPU stats to be printed in the wrong locations. Approved by: re (kib) MFC after: 1 week Revision Changes Path 1.17 +14 -2 src/contrib/top/display.c 1.31 +1 -1 src/contrib/top/top.c 1.103 +3 -5 src/usr.bin/top/machine.c