From owner-svn-src-head@freebsd.org Thu Aug 13 02:36:38 2015 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8F5D899FC40; Thu, 13 Aug 2015 02:36:38 +0000 (UTC) (envelope-from araujo@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 5C5312BB; Thu, 13 Aug 2015 02:36:38 +0000 (UTC) (envelope-from araujo@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.70]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id t7D2acVK072046; Thu, 13 Aug 2015 02:36:38 GMT (envelope-from araujo@FreeBSD.org) Received: (from araujo@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id t7D2abrC072044; Thu, 13 Aug 2015 02:36:37 GMT (envelope-from araujo@FreeBSD.org) Message-Id: <201508130236.t7D2abrC072044@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: araujo set sender to araujo@FreeBSD.org using -f From: Marcelo Araujo Date: Thu, 13 Aug 2015 02:36:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r286716 - in head/usr.bin: ypcat ypwhich X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Aug 2015 02:36:38 -0000 Author: araujo Date: Thu Aug 13 02:36:37 2015 New Revision: 286716 URL: https://svnweb.freebsd.org/changeset/base/286716 Log: Use nitems instead of "sizeof ypaliases/sizeof ypaliases[0]". Make the if statement more expressive. Differential Revision: D3366 Reviewed by: ed Approved by: bapt, rodrigc (mentor) Modified: head/usr.bin/ypcat/ypcat.c head/usr.bin/ypwhich/ypwhich.c Modified: head/usr.bin/ypcat/ypcat.c ============================================================================== --- head/usr.bin/ypcat/ypcat.c Thu Aug 13 02:31:23 2015 (r286715) +++ head/usr.bin/ypcat/ypcat.c Thu Aug 13 02:36:37 2015 (r286716) @@ -96,7 +96,7 @@ main(int argc, char *argv[]) while ((c = getopt(argc, argv, "xd:kt")) != -1) switch (c) { case 'x': - for (i=0; i