# HG changeset patch # User Paul Eggert # Date 1381934873 25200 # Node ID 53cc6ef9fb04399e0ff4a0b28ae9319f55937d35 # Parent 9a5e8b72769e71a35a74e583ce575bafbdae5dbc mkfifo-tests, etc.: allow HP-UX 11.11 bug Problem reported by Daniel Richard G. in . * doc/posix-functions/mkfifo.texi (mkfifo): * doc/posix-functions/mkfifoat.texi (mkfifoat): * doc/posix-functions/mknod.texi (mknod): * doc/posix-functions/mknodat.texi (mknodat): Document the HP-UX 11.11 bug. * tests/test-mkfifo.h (test_mkfifo): Allow the HP-UX 11.11 bug. diff -r 9a5e8b72769e -r 53cc6ef9fb04 ChangeLog --- a/ChangeLog Mon Oct 14 14:25:06 2013 -0700 +++ b/ChangeLog Wed Oct 16 07:47:53 2013 -0700 @@ -1,3 +1,16 @@ +2013-10-16 Paul Eggert + + mkfifo-tests, etc.: allow HP-UX 11.11 bug + Problem reported by Daniel Richard G. in + . + * doc/posix-functions/mkfifo.texi (mkfifo): + * doc/posix-functions/mkfifoat.texi (mkfifoat): + * doc/posix-functions/mknod.texi (mknod): + * doc/posix-functions/mknodat.texi (mknodat): + Document the HP-UX 11.11 bug. + * tests/test-mkfifo.h (test_mkfifo): + Allow the HP-UX 11.11 bug. + 2013-10-14 Paul Eggert acl: allow cross-compilation to Gentoo diff -r 9a5e8b72769e -r 53cc6ef9fb04 doc/posix-functions/mkfifo.texi --- a/doc/posix-functions/mkfifo.texi Mon Oct 14 14:25:06 2013 -0700 +++ b/doc/posix-functions/mkfifo.texi Wed Oct 16 07:47:53 2013 -0700 @@ -19,4 +19,8 @@ Portability problems not fixed by Gnulib: @itemize +@item +If the argument exists and is a directory, this function fails with +@code{EISDIR} instead of the correct @code{EEXIST}: +HP-UX 11.11. @end itemize diff -r 9a5e8b72769e -r 53cc6ef9fb04 doc/posix-functions/mkfifoat.texi --- a/doc/posix-functions/mkfifoat.texi Mon Oct 14 14:25:06 2013 -0700 +++ b/doc/posix-functions/mkfifoat.texi Wed Oct 16 07:47:53 2013 -0700 @@ -20,6 +20,9 @@ @itemize @item The gnulib replacement function always fails with @samp{ENOSYS} on -some platforms: -mingw, MSVC 9. +some platforms: mingw, MSVC 9. +@item +If the argument exists and is a directory, the gnulib replacement +function fails with @code{EISDIR} instead of the correct +@code{EEXIST}: HP-UX 11.11. @end itemize diff -r 9a5e8b72769e -r 53cc6ef9fb04 doc/posix-functions/mknod.texi --- a/doc/posix-functions/mknod.texi Mon Oct 14 14:25:06 2013 -0700 +++ b/doc/posix-functions/mknod.texi Wed Oct 16 07:47:53 2013 -0700 @@ -26,4 +26,8 @@ Use of this function for anything except fifos is not portable, generally requiring super-user privileges and knowledge of supported device numbers. +@item +If the argument exists and is a directory, this function fails with +@code{EISDIR} instead of the correct @code{EEXIST}: +HP-UX 11.11. @end itemize diff -r 9a5e8b72769e -r 53cc6ef9fb04 doc/posix-functions/mknodat.texi --- a/doc/posix-functions/mknodat.texi Mon Oct 14 14:25:06 2013 -0700 +++ b/doc/posix-functions/mknodat.texi Wed Oct 16 07:47:53 2013 -0700 @@ -22,4 +22,8 @@ The gnulib replacement function always fails with @samp{ENOSYS} on some platforms: mingw, MSVC 9. +@item +If the argument exists and is a directory, the gnulib replacement +function fails with @code{EISDIR} instead of the correct +@code{EEXIST}: HP-UX 11.11. @end itemize diff -r 9a5e8b72769e -r 53cc6ef9fb04 tests/test-mkfifo.h --- a/tests/test-mkfifo.h Mon Oct 14 14:25:06 2013 -0700 +++ b/tests/test-mkfifo.h Wed Oct 16 07:47:53 2013 -0700 @@ -43,7 +43,10 @@ ASSERT (errno == ENOENT); errno = 0; ASSERT (func (".", 0600) == -1); - ASSERT (errno == EEXIST || errno == EINVAL); + /* Allow HP-UX 11.11's EISDIR, even though POSIX says it's wrong, + since it doesn't really hurt anything and we lack the energy to + fix it. */ + ASSERT (errno == EEXIST || errno == EINVAL || errno == EISDIR); errno = 0; ASSERT (func (BASE "fifo", 0600) == -1); ASSERT (errno == EEXIST);