From: Junio C Hamano <gitster@pobox.com>
To: Patrick Steinhardt <ps@pks.im>
Cc: git@vger.kernel.org, Chuck Lever <chuck.lever@oracle.com>,
rsbecker@nexbridge.com, Jeff King <peff@peff.net>,
linux-nfs@vger.kernel.org
Subject: Re: [PATCH] reftable: fix tests being broken by NFS' delete-after-close semantics
Date: Thu, 21 Mar 2024 10:35:19 -0700 [thread overview]
Message-ID: <xmqqsf0j8p48.fsf@gitster.g> (raw)
In-Reply-To: <8ac5e94a3930cdd2aee9ea86acda3155674b635c.1711035529.git.ps@pks.im> (Patrick Steinhardt's message of "Thu, 21 Mar 2024 16:39:52 +0100")
Patrick Steinhardt <ps@pks.im> writes:
> while ((d = readdir(dir))) {
> - if (!strcmp(d->d_name, "..") || !strcmp(d->d_name, "."))
> + /*
> + * Besides skipping over "." and "..", we also need to
> + * skip over other files that have a leading ".". This
> + * is due to behaviour of NFS, which will rename files
> + * to ".nfs*" to emulate delete-on-last-close.
> + *
> + * In any case this should be fine as the reftable
> + * library will never write files with leading dots
> + * anyway.
> + */
> + if (starts_with(d->d_name, "."))
> continue;
Sounds good. We should count what we positively consider what we
wrote, not random cruft somebody else might have dropped in the
directory, and this is a good first thing to do.
Will queue. Thanks.
next prev parent reply other threads:[~2024-03-21 17:35 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-12 15:10 t0032 fails on NFS mounts Chuck Lever
2024-03-12 17:11 ` rsbecker
2024-03-21 15:50 ` Patrick Steinhardt
2024-03-13 7:20 ` Jeff King
2024-03-15 0:35 ` Patrick Steinhardt
2024-03-15 15:41 ` Junio C Hamano
2024-03-21 15:14 ` Patrick Steinhardt
2024-03-21 15:39 ` [PATCH] reftable: fix tests being broken by NFS' delete-after-close semantics Patrick Steinhardt
2024-03-21 17:35 ` Junio C Hamano [this message]
2024-03-22 15:15 ` Toon Claes
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=xmqqsf0j8p48.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=chuck.lever@oracle.com \
--cc=git@vger.kernel.org \
--cc=linux-nfs@vger.kernel.org \
--cc=peff@peff.net \
--cc=ps@pks.im \
--cc=rsbecker@nexbridge.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.