From: Kamil Dudka <kdudka@redhat.com>
To: Bernhard Voelker <mail@bernhard-voelker.de>
Cc: bug-gnulib <bug-gnulib@gnu.org>
Subject: Re: tests: dis/allow '.' in PATH?
Date: Wed, 24 Nov 2021 08:24:58 +0100 [thread overview]
Message-ID: <5769878.lOV4Wx5bFT@nbkamil> (raw)
In-Reply-To: <7efa54e6-e6dc-822b-8eaa-18177a52b0a1@bernhard-voelker.de>
On Tuesday, November 23, 2021 11:19:22 PM CET Bernhard Voelker wrote:
> GNU findutils got a bug report for a failing test in the testsuite [1].
> It turned out that the calling environment had the current directory '.'
> in PATH. This triggered a warning in `find -execdir ...` and therefore
> made some tests fail.
>
> [1] https://lists.gnu.org/r/bug-findutils/2021-11/msg00004.html
>
> Of course, the findutils tests could (and probably will) remove '.' from
> PATH, but I wonder if this should or should not be done for other packages
> via a change in 'tests/init.sh' as well?
> If a certain test needs '.' in the PATH, it will have to add it anyway.
>
> Any comments?
Note that having an "empty item" in PATH will have the same effect as
having '.' in PATH, according to POSIX [1]:
A zero-length prefix is a legacy feature that indicates the current
working directory. It appears as two adjacent <colon> characters
( "::" ), as an initial <colon> preceding the rest of the list, or
as a trailing <colon> following the rest of the list.
Kamil
[1] https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap08.html#tag_08_03
next prev parent reply other threads:[~2021-11-24 7:41 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-11-23 22:19 tests: dis/allow '.' in PATH? Bernhard Voelker
2021-11-24 0:10 ` Paul Eggert
2021-11-24 7:24 ` Kamil Dudka [this message]
2021-11-24 23:03 ` Bernhard Voelker
2021-11-24 23:54 ` Paul Eggert
2021-11-26 0:10 ` Bernhard Voelker
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
List information: https://lists.gnu.org/mailman/listinfo/bug-gnulib
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5769878.lOV4Wx5bFT@nbkamil \
--to=kdudka@redhat.com \
--cc=bug-gnulib@gnu.org \
--cc=mail@bernhard-voelker.de \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).