From nobody Tue Sep 03 10:26:53 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4Wyhct1Q0pz5MkWL; Tue, 03 Sep 2024 10:26:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Wyhcs5XjJz4rqh; Tue, 3 Sep 2024 10:26:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1725359213; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=q3h4g3PxTwSchPhU7Zv5h4bjo8PbqKTPBrxfYcGLUwE=; b=B/zm+NVxP+WPertStdIKq/UDnDs8T0PUs84M7h4QOBzYqSM0KOVg4j71cQHILayZbwl+FX BrZAqQA2mTjY16KImqrxMH1UP0im06mvuU+Y9P0X3JjO22w+oLj9C+H8cCN/795r9zebrz btR2mcV0kWDbl/9KNfLYwD95jBX3MvX7hMiN/ZURreATzDjVpKeYcm6CMTL+pIiCIGvisg Dfg6Io5wdXM/gApv2Un8dVtmMY1Ho91scO7gs2umYnTQITnnufs9ruywLqbckZja4s4rGz GTY0Ym1xlgUYnPVAyFLxawxX2qQenauxqxcE40d1wxrQel85qTPOwDq9Fks4yA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1725359213; a=rsa-sha256; cv=none; b=VivaYjI/oWa3X4jAlnIYHlE4pjdbWIYrzhmZWlXeAbmmo7s+as/oVCeMpUT+dCDJQ1ynH3 yShcOWdZINcbMbbIFNIRBl4xBlhfHZYmr9mtm4U/jB3vBirRq0wbOCvvPD3hyjhDXfXd3O nfqNvJ85QssOzkyk8kgPvOBTSX/WLCVNgluRVhDeHl6ti4FqeaKPnc5j6JbzPFskKLU9Br xuLTi09wy1TbPYslgmebU1Kqe+LsPYFppYpCg6VZihKeByQs7rHVgzsJ6jplEkSvDSyFLM DWyI/5Tp8G8Yz1eP31hm0+8EvPsaoBoAfOKushK7I4lcfqZrU30L1IDePqZiyQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1725359213; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=q3h4g3PxTwSchPhU7Zv5h4bjo8PbqKTPBrxfYcGLUwE=; b=lZfvkDdkp26OUMqp2MPpbKN5TS5kqVF62a1PdMW2SntZ8PEC2tOIHsptnIeekolqB42og6 1yYFdiqrssq8FhsjZpDvxYubnDRemHyCu6dRzBp+ZebkezBS8XCknItoIF6SkvVU93pTWK 6vLQuk7/mYEmkzetisfhcegjMTxYzpjjiPHEIRALXx9dZr9ltchnA97uoAbxWpF3Oajhf1 VHohtSRf21rYZeFi/QBOteDEyWEyKMEp1JMnjjCNr2AzUcWLu00qwBkobuf9u/tm8xwpYv 5rlVP/moFxtnhJ1yOoWX4SF+s6kECpR//Xt+Vf0gwm+air8W0FbgPQ99s+Jk/g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4Wyhcs4fmhzcxn; Tue, 3 Sep 2024 10:26:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 483AQrlo009163; Tue, 3 Sep 2024 10:26:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 483AQr23009160; Tue, 3 Sep 2024 10:26:53 GMT (envelope-from git) Date: Tue, 3 Sep 2024 10:26:53 GMT Message-Id: <202409031026.483AQr23009160@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Zhenlei Huang Subject: git: 7a720bf67d73 - main - xdr: Stop checking for failures from malloc(M_WAITOK) List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: zlei X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 7a720bf67d73ba565a0a1130065f798870eb5faa Auto-Submitted: auto-generated The branch main has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=7a720bf67d73ba565a0a1130065f798870eb5faa commit 7a720bf67d73ba565a0a1130065f798870eb5faa Author: Zhenlei Huang AuthorDate: 2024-09-03 10:25:20 +0000 Commit: Zhenlei Huang CommitDate: 2024-09-03 10:25:20 +0000 xdr: Stop checking for failures from malloc(M_WAITOK) MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D45852 --- sys/xdr/xdr_sizeof.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/sys/xdr/xdr_sizeof.c b/sys/xdr/xdr_sizeof.c index 6b4ee0352c9e..bcacf918f4fd 100644 --- a/sys/xdr/xdr_sizeof.c +++ b/sys/xdr/xdr_sizeof.c @@ -94,10 +94,7 @@ x_inline(XDR *xdrs, u_int len) /* Free the earlier space and allocate new area */ if (xdrs->x_private) free(xdrs->x_private, M_RPC); - if ((xdrs->x_private = (caddr_t) malloc(len, M_RPC, M_WAITOK)) == NULL) { - xdrs->x_base = 0; - return (NULL); - } + xdrs->x_private = malloc(len, M_RPC, M_WAITOK); xdrs->x_base = (caddr_t)(uintptr_t) len; xdrs->x_handy += len; return ((int32_t *) xdrs->x_private);