From owner-svn-src-all@FreeBSD.ORG Thu Dec 1 15:01:23 2011 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DE4E21065677; Thu, 1 Dec 2011 15:01:23 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id CE6248FC1B; Thu, 1 Dec 2011 15:01:23 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id pB1F1Nrb050263; Thu, 1 Dec 2011 15:01:23 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id pB1F1NHX050261; Thu, 1 Dec 2011 15:01:23 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201112011501.pB1F1NHX050261@svn.freebsd.org> From: John Baldwin Date: Thu, 1 Dec 2011 15:01:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r228181 - head/sbin/sysctl X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 01 Dec 2011 15:01:24 -0000 Author: jhb Date: Thu Dec 1 15:01:23 2011 New Revision: 228181 URL: http://svn.freebsd.org/changeset/base/228181 Log: If the -d flag is specified, ignore any new values specified and only display the descriptions of specified nodes. Reported by: Jason Hellenthal jhell of dataix net MFC after: 2 weeks Modified: head/sbin/sysctl/sysctl.c Modified: head/sbin/sysctl/sysctl.c ============================================================================== --- head/sbin/sysctl/sysctl.c Thu Dec 1 13:53:33 2011 (r228180) +++ head/sbin/sysctl/sysctl.c Thu Dec 1 15:01:23 2011 (r228181) @@ -201,7 +201,7 @@ parse(char *string) if (oidfmt(mib, len, fmt, &kind)) err(1, "couldn't find format of oid '%s'", bufp); - if (newval == NULL) { + if (newval == NULL || dflag) { if ((kind & CTLTYPE) == CTLTYPE_NODE) { if (dflag) { i = show_var(mib, len);