From owner-svn-src-user@freebsd.org Sun Jan 3 07:40:12 2016 Return-Path: Delivered-To: svn-src-user@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 AE2A7A5F63F for ; Sun, 3 Jan 2016 07:40:12 +0000 (UTC) (envelope-from ngie@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 826D11C00; Sun, 3 Jan 2016 07:40:12 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u037eB00098540; Sun, 3 Jan 2016 07:40:11 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u037eBti098539; Sun, 3 Jan 2016 07:40:11 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201601030740.u037eBti098539@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Garrett Cooper Date: Sun, 3 Jan 2016 07:40:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r293082 - user/ngie/stable-10-libnv/sys/kern X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 03 Jan 2016 07:40:12 -0000 Author: ngie Date: Sun Jan 3 07:40:11 2016 New Revision: 293082 URL: https://svnweb.freebsd.org/changeset/base/293082 Log: MFC r282249: r282249 (by oshogbo): Always use the nv_malloc macro instead of malloc(3). Modified: user/ngie/stable-10-libnv/sys/kern/subr_nvlist.c Directory Properties: user/ngie/stable-10-libnv/ (props changed) Modified: user/ngie/stable-10-libnv/sys/kern/subr_nvlist.c ============================================================================== --- user/ngie/stable-10-libnv/sys/kern/subr_nvlist.c Sun Jan 3 07:37:46 2016 (r293081) +++ user/ngie/stable-10-libnv/sys/kern/subr_nvlist.c Sun Jan 3 07:40:11 2016 (r293082) @@ -927,7 +927,7 @@ nvlist_recv(int sock, int flags) nfds = (size_t)nvlhdr.nvlh_descriptors; size = sizeof(nvlhdr) + (size_t)nvlhdr.nvlh_size; - buf = malloc(size); + buf = nv_malloc(size); if (buf == NULL) return (NULL); @@ -940,7 +940,7 @@ nvlist_recv(int sock, int flags) goto out; if (nfds > 0) { - fds = malloc(nfds * sizeof(fds[0])); + fds = nv_malloc(nfds * sizeof(fds[0])); if (fds == NULL) goto out; if (fd_recv(sock, fds, nfds) == -1)