From owner-svn-src-head@freebsd.org Mon Apr 10 22:56:40 2017 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 0D33DD37B2B; Mon, 10 Apr 2017 22:56:40 +0000 (UTC) (envelope-from pfg@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 C5C3B88A; Mon, 10 Apr 2017 22:56:39 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v3AMucrm091690; Mon, 10 Apr 2017 22:56:38 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v3AMucPC091689; Mon, 10 Apr 2017 22:56:38 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201704102256.v3AMucPC091689@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Mon, 10 Apr 2017 22:56:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r316695 - head/cddl/contrib/opensolaris/lib/libzfs/common 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.23 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: Mon, 10 Apr 2017 22:56:40 -0000 Author: pfg Date: Mon Apr 10 22:56:38 2017 New Revision: 316695 URL: https://svnweb.freebsd.org/changeset/base/316695 Log: MFV r316693: 8046 Let calloc() do the multiplication in libzfs_fru_refresh https://github.com/illumos/illumos-gate/commit/5697e03e6e3e2697f56ae341c7c8ce79680d6a2e https://www.illumos.org/issues/8046 Reviewed by: Matthew Ahrens Reviewed by: Paul Dagnelie Approved by: Robert Mustacchi Author: Pedro Giffuni MFC after: 3 days Modified: head/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_fru.c Directory Properties: head/cddl/contrib/opensolaris/ (props changed) head/cddl/contrib/opensolaris/lib/libzfs/ (props changed) Modified: head/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_fru.c ============================================================================== --- head/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_fru.c Mon Apr 10 22:47:18 2017 (r316694) +++ head/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_fru.c Mon Apr 10 22:56:38 2017 (r316695) @@ -282,7 +282,7 @@ libzfs_fru_refresh(libzfs_handle_t *hdl) if (hdl->libzfs_fru_hash == NULL && (hdl->libzfs_fru_hash = - calloc(ZFS_FRU_HASH_SIZE * sizeof (void *), 1)) == NULL) + calloc(ZFS_FRU_HASH_SIZE, sizeof (void *))) == NULL) return; /*