From owner-svn-src-head@freebsd.org Wed Apr 27 02:13:58 2016 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 8D0F4B1DE92; Wed, 27 Apr 2016 02:13:58 +0000 (UTC) (envelope-from araujo@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::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 505D918BF; Wed, 27 Apr 2016 02:13:58 +0000 (UTC) (envelope-from araujo@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u3R2DvRt042407; Wed, 27 Apr 2016 02:13:57 GMT (envelope-from araujo@FreeBSD.org) Received: (from araujo@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u3R2DvH8042406; Wed, 27 Apr 2016 02:13:57 GMT (envelope-from araujo@FreeBSD.org) Message-Id: <201604270213.u3R2DvH8042406@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: araujo set sender to araujo@FreeBSD.org using -f From: Marcelo Araujo Date: Wed, 27 Apr 2016 02:13:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r298682 - head/usr.bin/quota 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.21 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: Wed, 27 Apr 2016 02:13:58 -0000 Author: araujo Date: Wed Apr 27 02:13:57 2016 New Revision: 298682 URL: https://svnweb.freebsd.org/changeset/base/298682 Log: Use MIN() macro from sys/param.h. MFC after: 2 weeks. Modified: head/usr.bin/quota/quota.c Modified: head/usr.bin/quota/quota.c ============================================================================== --- head/usr.bin/quota/quota.c Wed Apr 27 02:02:44 2016 (r298681) +++ head/usr.bin/quota/quota.c Wed Apr 27 02:13:57 2016 (r298682) @@ -266,8 +266,8 @@ prthumanval(int len, u_int64_t bytes) /* * Limit the width to 5 bytes as that is what users expect. */ - humanize_number(buf, sizeof(buf) < 5 ? sizeof(buf) : 5, bytes, "", - HN_AUTOSCALE, HN_B | HN_NOSPACE | HN_DECIMAL); + humanize_number(buf, MIN(sizeof(buf), 5), bytes, "", + HN_AUTOSCALE, HN_B | HN_NOSPACE | HN_DECIMAL); (void)printf(" %*s", len, buf); }