bug-gnulib
[Top][All Lists]
Advanced

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

Re: POSIX modules status


From: Jim Meyering
Subject: Re: POSIX modules status
Date: Sun, 19 Jun 2011 16:37:16 +0200

Bruno Haible wrote:
>>       2 x FAIL: test-linkat
>
> On AIX 7.1, the linkat() function apparently fails with EINVAL when on
> Linux it returns other errno values. Here's the minimal change to make
> the test pass. OK to apply?
>
>
> 2011-06-19  Bruno Haible  <address@hidden>
>
>       linkat test: Avoid test failure on AIX 7.1.
>       * tests/test-linkat.c (main): Allow EINVAL as alternate error value.
>       * tests/test-link.h (test_link): Likewise.

Fine by me.
It's getting pretty messy, but that is less of a concern
with a test than with the code in lib/.
Thanks!

> --- tests/test-link.h.orig    Sun Jun 19 16:30:07 2011
> +++ tests/test-link.h Sun Jun 19 16:22:23 2011
> @@ -115,10 +115,10 @@
>    ASSERT (errno == ENOENT);
>    errno = 0;
>    ASSERT (func (BASE "a/", BASE "c") == -1);
> -  ASSERT (errno == ENOTDIR);
> +  ASSERT (errno == ENOTDIR || errno == EINVAL);
>    errno = 0;
>    ASSERT (func (BASE "a", BASE "c/") == -1);
> -  ASSERT (errno == ENOTDIR || errno == ENOENT);
> +  ASSERT (errno == ENOTDIR || errno == ENOENT || errno == EINVAL);
>
>    /* Most platforms reject hard links to directories, and even on
>       those that do permit it, most users can't create them.  We assume
> @@ -164,11 +164,12 @@
>      }
>    errno = 0;
>    ASSERT (func (BASE "b", BASE "link/") == -1);
> -  ASSERT (errno == ENOTDIR || errno == ENOENT || errno == EEXIST);
> +  ASSERT (errno == ENOTDIR || errno == ENOENT || errno == EEXIST
> +          || errno == EINVAL);



reply via email to

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