From nobody Sun May 12 00:08:36 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 4VcNJ44F4sz5JbXQ; Sun, 12 May 2024 00:08:36 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VcNJ42WhZz4tN9; Sun, 12 May 2024 00:08:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1715472516; 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=dlU7tc0U5YpsnvMi0hXGYZBzqn142GELSm3KvfB70Xw=; b=dfibRN4yMzpHSciLjDMnFGtJ2HtBZmF2H+WQFj/DsqdwU4DqQ1RpTzCcOQWFouZGZjVdJv DxFduw9ik0ScGPg6tkKfYB2JwB3zANIz9j4g5gWAKai4L4jKg8Nhag5M8coki/vxO7ADoW B6Z2OGyMrsgUKk9DZfhDzRPl22apQlaBwceZG6HannwmiccIKVrPtSYsC8QJiZx3FpwxD0 sIwHSXrAmGm9JoL1LNJKVWUEQ6mbhGvG+eas5Gcw93IwwGtRvzUCmjUX9TxUI6Um+PoEOT xe127wEG8MU0V/i5MTbI9x4ooWa4IJHicS4QfnEQAl4d3rQdQPJ36l2UOUCrsw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1715472516; a=rsa-sha256; cv=none; b=UR5yJ1g+jQt9ovgJibRtCiCz84m5+LZ1iCu1iyJgvs9tjvWZ1H1quDVxwHMT6lR40+/Dl1 2FdfaNmYKp95CdTKne1B8TUwjFWlqTuiKl7DVbsGRKWGENVW0e8b9JA9KwFT2HGqnshwTG jO/ZERWMgx7R5LDxnceNKdUiEqcF/l3/Zt6tjIM6f595XwmsR3aTQoDsf7QuLSitkfaaXe xpTHq0FCpGGyEQTTi3LsvMn+Iv2OWriwImaNhHFNeF+mAD8i+D11B/rVGhY1EuAOr0omOu bRcwGlnncCIooV1FI3yUKHCngai1chVlqByyAH9JZar+ELaIQqkM7HMRxOG8aw== 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=1715472516; 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=dlU7tc0U5YpsnvMi0hXGYZBzqn142GELSm3KvfB70Xw=; b=k9K6Xv4gdEnr3gTpVghPED+xvCdSEmADpLxG81p0O9BAhS1fGFkiJlUIhPBwYVk6kANUJZ nEUW5Mao93Bph2IEgANxYfyqkZC35qMPvZzvNIkCAhmglxXXg2YStoNsYzj+uWk+LJNNg4 6s2JfgNW6k1k9Z7JlMsT4tGpk4WaFx4RexuwR8iSDBb/ldCLVMeNM09mcqyL2ANX8f2vMV Uxq7O1yFDDfvyQUk6O0SozWvxzkG1mrRpdFwGeX9Paehw//Jt4g3Ucq7oys1+wqy355CRW XScygWRQiLSCp+nwMs9upS+Gqa7ZSjgNJNPnnxz65vDEUF4s6O1joyZgMegkhQ== 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 4VcNJ41tSvzh64; Sun, 12 May 2024 00:08:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 44C08aw8002183; Sun, 12 May 2024 00:08:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 44C08a3S002180; Sun, 12 May 2024 00:08:36 GMT (envelope-from git) Date: Sun, 12 May 2024 00:08:36 GMT Message-Id: <202405120008.44C08a3S002180@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Jake Freeland Subject: git: dee055d1b1e6 - stable/14 - uipc_shm: Fix a free() of an uninitialized variable 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: jfree X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: dee055d1b1e602da77016fd14cb003896586f864 Auto-Submitted: auto-generated The branch stable/14 has been updated by jfree: URL: https://cgit.FreeBSD.org/src/commit/?id=dee055d1b1e602da77016fd14cb003896586f864 commit dee055d1b1e602da77016fd14cb003896586f864 Author: Mark Johnston AuthorDate: 2024-04-19 00:15:51 +0000 Commit: Jake Freeland CommitDate: 2024-05-11 23:57:44 +0000 uipc_shm: Fix a free() of an uninitialized variable Reported by: Coverity CID: 1544043 Fixes: b112232e4fb9 ("uipc_shm: Copyin userpath for ktrace(2)") (cherry picked from commit e411b2273603267dbc51c7839879e765b573c1c5) --- sys/kern/uipc_shm.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/kern/uipc_shm.c b/sys/kern/uipc_shm.c index 31c80913be84..0bfbc636e405 100644 --- a/sys/kern/uipc_shm.c +++ b/sys/kern/uipc_shm.c @@ -1214,6 +1214,8 @@ kern_shm_open2(struct thread *td, const char *userpath, int flags, mode_t mode, #endif AUDIT_ARG_UPATH1_CANON(path); + } else { + path = NULL; } pdp = td->td_proc->p_pd;