From nobody Sat Feb 11 15:28:34 2023 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 4PDZJJ1D1Cz3pC08; Sat, 11 Feb 2023 15:28:48 +0000 (UTC) (envelope-from asomers@gmail.com) Received: from mail-vk1-f175.google.com (mail-vk1-f175.google.com [209.85.221.175]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1D4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4PDZJH6Gy8z3wxv; Sat, 11 Feb 2023 15:28:47 +0000 (UTC) (envelope-from asomers@gmail.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-vk1-f175.google.com with SMTP id v5so4147982vkc.10; Sat, 11 Feb 2023 07:28:47 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1676129326; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=J9gT89HxtDt1eLCfal1xO7NJ4Npi2clW8ip7H1XMz/Q=; b=JZQURGlXQqgoHIdgfqKmQTDLlDW763xoaXixl22yE4k+XHbUbY0+zRH3x6obQ1ZMhp n62Cjx4z1To0Ri+sYDgTIsyOgVFl+YX1yBgg65MJek7pXWHBK9NsW2Pq9xHtz3bASmhJ F8eaLjunctj277t+BbGK8QuIIbilp6sRMIMMlnJTHv34YzsKFqqT9itO7r2nNvm6XHJR tBgdLgmNn/YSgJ5sOkGeZ8QxxRF8/6ahE08VuAATxYId0o8iD2tyiHMx42kzKKkVUWDw B1XnHSN+IgXRGBL1Bb/66u2Ot+uTc5L+nTwMb5UzKesVMKcvGytaj4UMVDkKtd1OwsOF P6iQ== X-Gm-Message-State: AO0yUKWqalqWyA6BJR/ZhapdQ+MzDOURbMgV29NMQogWMeyWUymrpan5 o4pyrcZqIlYHAUHMv9gNoDFslTrYNWmH5BY3nvdm1QCV X-Google-Smtp-Source: AK7set8VpvirAjK0dUWaqix7/aVnUK7Yd6FPSxSQlPbYH0LV6W1PYCgA6wSlz7CelP35wvO+sDyplXZNxP4qWVYNsiU= X-Received: by 2002:a1f:5804:0:b0:3e1:f8b0:e35d with SMTP id m4-20020a1f5804000000b003e1f8b0e35dmr3797732vkb.35.1676129326013; Sat, 11 Feb 2023 07:28:46 -0800 (PST) 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: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 References: <202302110704.31B74Bvm047614@gitrepo.freebsd.org> In-Reply-To: <202302110704.31B74Bvm047614@gitrepo.freebsd.org> From: Alan Somers Date: Sat, 11 Feb 2023 08:28:34 -0700 Message-ID: Subject: Re: git: cbac1f346495 - main - Fix pjfstest issue tests/rename/09.t To: Fedor Uporov Cc: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Content-Type: text/plain; charset="UTF-8" X-Rspamd-Queue-Id: 4PDZJH6Gy8z3wxv X-Spamd-Bar: ---- X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:15169, ipnet:209.85.128.0/17, country:US] X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-ThisMailContainsUnwantedMimeParts: N On Sat, Feb 11, 2023 at 12:04 AM Fedor Uporov wrote: > > The branch main has been updated by fsu: > > URL: https://cgit.FreeBSD.org/src/commit/?id=cbac1f3464956185cf95955344b6009e2cc3ae40 > > commit cbac1f3464956185cf95955344b6009e2cc3ae40 > Author: Fedor Uporov > AuthorDate: 2023-02-02 10:13:02 +0000 > Commit: Fedor Uporov > CommitDate: 2023-02-11 07:01:16 +0000 > > Fix pjfstest issue tests/rename/09.t > > Fix rename when renamed directory not owned by user, > but when user owns the sticky parent directory. > > Reviewed by: kib > MFC after: 2 week > Differential revision: https://reviews.freebsd.org/D38245 > --- > sys/fs/tmpfs/tmpfs_vnops.c | 7 +++++++ > 1 file changed, 7 insertions(+) > > diff --git a/sys/fs/tmpfs/tmpfs_vnops.c b/sys/fs/tmpfs/tmpfs_vnops.c > index 55f0beebc848..28de8c989487 100644 > --- a/sys/fs/tmpfs/tmpfs_vnops.c > +++ b/sys/fs/tmpfs/tmpfs_vnops.c > @@ -1129,6 +1129,13 @@ tmpfs_rename(struct vop_rename_args *v) > if (de->td_node->tn_type == VDIR) { > struct tmpfs_node *n; > > + error = VOP_ACCESS(fvp, VWRITE, tcnp->cn_cred, curthread); > + if (error) { > + if (newname != NULL) > + free(newname, M_TMPFSNAME); > + goto out_locked; > + } > + > /* > * Ensure the target directory is not a child of the > * directory being moved. Otherwise, we'd end up Nice. I'm glad to see that people are getting good use out of pjdfstest.