bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: openat-safer: Avoid test failure on NetBSD 8


From: Jim Meyering
Subject: Re: openat-safer: Avoid test failure on NetBSD 8
Date: Sat, 15 Dec 2018 17:28:28 -0800

On Sat, Dec 15, 2018 at 3:50 PM Bruno Haible <address@hidden> wrote:
> While testing a grep snapshot on NetBSD 8, I see that the gnulib test
> 'test-openat-safer' fails:
>
> FAIL: test-openat-safer
> =======================
>
> ../../gnulib-tests/test-openat-safer.c:101: assertion 'STDERR_FILENO < fd' 
> failed
> FAIL test-openat-safer (exit status: 134)
>
>
> The reason is that the test is too strong: It verifies that
> "Using a bad directory is okay for absolute paths". But this is not guaranteed
> by POSIX [1] (as far as I understand it). Only the Linux man page specifies
> this [2].
>
> So let's conditionalize this test.
>
> [1] http://pubs.opengroup.org/onlinepubs/9699919799/functions/open.html
> [2] https://linux.die.net/man/2/openat
>
> 2018-12-15  Bruno Haible  <address@hidden>
>
>         openat-safer tests: Avoid test failure on NetBSD 8.
>         * tests/test-openat-safer.c (main): Execute a Linux specific test only
>         on Linux.

Looks fine to me. Thank you, Bruno.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]