# HG changeset patch # User Bruno Haible # Date 1316601800 -7200 # Node ID dc8a8ac8cdd843c4944709fc533c01fdc61d7f9d # Parent bad19c8ddacb64dc373f8dd1749f277a138c735e unlockpt tests: Avoid test failure on NetBSD 5.1. * tests/test-unlockpt.c (main): Skip the EBADF tests on NetBSD. * doc/posix-functions/unlockpt.texi: Mention the bug on NetBSD. diff --git a/ChangeLog b/ChangeLog --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2011-09-21 Bruno Haible + + unlockpt tests: Avoid test failure on NetBSD 5.1. + * tests/test-unlockpt.c (main): Skip the EBADF tests on NetBSD. + * doc/posix-functions/unlockpt.texi: Mention the bug on NetBSD. + 2011-09-21 Bruno Haible getlogin, getlogin_r tests: Avoid test failure on Linux/SPARC. diff --git a/doc/posix-functions/unlockpt.texi b/doc/posix-functions/unlockpt.texi --- a/doc/posix-functions/unlockpt.texi +++ b/doc/posix-functions/unlockpt.texi @@ -17,5 +17,5 @@ @itemize @item This function reports success for invalid file descriptors on some platforms: -Cygwin 1.7.9. +NetBSD 5.1, Cygwin 1.7.9. @end itemize diff --git a/tests/test-unlockpt.c b/tests/test-unlockpt.c --- a/tests/test-unlockpt.c +++ b/tests/test-unlockpt.c @@ -29,6 +29,7 @@ main (void) { /* Test behaviour for invalid file descriptors. */ +#if !defined __NetBSD__ /* known bug on NetBSD 5.1 */ { errno = 0; ASSERT (unlockpt (-1) == -1); @@ -43,6 +44,7 @@ || errno == EINVAL /* seen on FreeBSD 6.4 */ ); } +#endif return 0; }