From nobody Sun Sep 1 00:55:05 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 4WxD2145dyz5MQsg; Sun, 01 Sep 2024 00:55:05 +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 4WxD213fXPz49hL; Sun, 1 Sep 2024 00:55:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1725152105; 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=S7GN5bMPB/mN51SQMxFngxvsVeGqAcn6uxI4C+ofqp4=; b=jPA2okdMCh+yIeKj5M2W5TTvwZQ34sZH1hbsGAUZYv9uIUixliA/ynvmdAMnr7yQrrKZ6Z pf1U7pnNjc/5wMVMXGqmiBwIINw2OL7kuNFdThMiQprGbks66FBOL4aZ+xBwWA+j4YSCck 5fYqEZrqyuIheQINpM1MeWbCJPAoHI+ramFusOl/7SYMhCl4YkH42OKlVtHoftRY7znbpe rSOicCfP/rBC7YvC5kSPJoqcp+kvSZn6ChphtOtq48fj94MznGpu2vrYVL+ADsuu9Q0aZ3 fHp94kDS8dYwWMWo0EpdabaolzG4Uo1ANmvOkym2UTKtpUrhqqU/N7+w9OuNWg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1725152105; a=rsa-sha256; cv=none; b=yNXSKcQr9lc4v7pYbLyLx98xCxbiKL6DCAHOw2gbr/PKIjUeTeR7Thda1obowLeNQZ6eYR QEVKOPP7XU+ijQ0xkNBJij0j1c4Sbuze6ChexAuXNWlCHp4A639Jx1t3wUoIwP8lwwZOM8 VVRchbzai3n0pXxuhl6BKxcZOR8L2ZMlNmHiIhjoApwxgpAL9o7BzY85pcwGnmjP//i7co j4afVXWUUdF5jl3LdiQhogrDU46vR/pnhKaU/cchP5ZUJTidLHiBvuV7g2p2r4pbk/NT3x kk+Vul0MLO4G+WKkCD6H22RNENFimHlkK76E0DhdMw5Bn8UbRfqOfEf5Gr6ESA== 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=1725152105; 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=S7GN5bMPB/mN51SQMxFngxvsVeGqAcn6uxI4C+ofqp4=; b=fP+A6cg4GQCyflKIIQ6WICAHdiiqBAR/KksXGJRBwNY2rMIUprwP3ogF/ddszKO8j/cKPP fNuUDYyBg1CL3aG3AV1rqZuU46/Y/Xu54U3J+ecQWLAcVhF3KPXK3hsfrmFNZ8dR4XAP+u N8eFWF7rkOu23MOcdyKaSzybBSPS/2FAr9gsYJSxCdZq3QnfO1PxlfYXBLVEmQ9DY+2qLr 9KA/vGTLrrHJFlGMVirnTTjzP9rfs2xuSXB6PYAOPHrYUMaipXe3xNKC+AyVzqLKqsLm4l VBSDJ1dkvwzh9Kx9qhE2BnZJgYgei8hFHiL/JTEByaGlOpsb9l/VMOU2V3Ymkw== 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 4WxD2137d7z16PX; Sun, 1 Sep 2024 00:55:05 +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 4810t55i059286; Sun, 1 Sep 2024 00:55:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4810t5au059283; Sun, 1 Sep 2024 00:55:05 GMT (envelope-from git) Date: Sun, 1 Sep 2024 00:55:05 GMT Message-Id: <202409010055.4810t5au059283@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: 65ae1d493e31 - stable/14 - msdosfs: return ENOENT if looking up invalid name for OPEN or DELETE 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: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 65ae1d493e314f5270cc92315cea0bb2e1afa3b0 Auto-Submitted: auto-generated The branch stable/14 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=65ae1d493e314f5270cc92315cea0bb2e1afa3b0 commit 65ae1d493e314f5270cc92315cea0bb2e1afa3b0 Author: Jose Luis Duran AuthorDate: 2024-08-25 14:50:53 +0000 Commit: Konstantin Belousov CommitDate: 2024-09-01 00:53:36 +0000 msdosfs: return ENOENT if looking up invalid name for OPEN or DELETE PR: 281033 (cherry picked from commit 0b2c159c8faa3ca155412a1b2e57b3d6bcf91880) --- sys/fs/msdosfs/msdosfs_lookup.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sys/fs/msdosfs/msdosfs_lookup.c b/sys/fs/msdosfs/msdosfs_lookup.c index 2a90339d0878..e799a5ce05f6 100644 --- a/sys/fs/msdosfs/msdosfs_lookup.c +++ b/sys/fs/msdosfs/msdosfs_lookup.c @@ -198,7 +198,9 @@ msdosfs_lookup_ino(struct vnode *vdp, struct vnode **vpp, struct componentname switch (unix2dosfn((const u_char *)cnp->cn_nameptr, dosfilename, cnp->cn_namelen, 0, pmp)) { case 0: - return (EINVAL); + if (nameiop == CREATE || nameiop == RENAME) + return (EINVAL); + return (ENOENT); case 1: break; case 2: