changeset 14016:fdade8a28ed5

select tests: Avoid failures on OSF/1 5.1. * tests/test-select.c (test_accept_first, test_socket_pair): Ignore failure of closing the last socket; it may fail with ECONNRESET.
author Bruno Haible <bruno@clisp.org>
date Sat, 25 Dec 2010 01:26:18 +0100
parents 41026f5e29c1
children 1d257f14690f
files ChangeLog tests/test-select.c
diffstat 2 files changed, 8 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Fri Dec 24 13:39:50 2010 -0700
+++ b/ChangeLog	Sat Dec 25 01:26:18 2010 +0100
@@ -1,3 +1,9 @@
+2010-12-24  Bruno Haible  <bruno@clisp.org>
+
+	select tests: Avoid failures on OSF/1 5.1.
+	* tests/test-select.c (test_accept_first, test_socket_pair): Ignore
+	failure of closing the last socket; it may fail with ECONNRESET.
+
 2010-12-24  Eric Blake  <eblake@redhat.com>
 
 	stdint: avoid HP-UX 10.20 preprocessor bug
--- a/tests/test-select.c	Fri Dec 24 13:39:50 2010 -0700
+++ b/tests/test-select.c	Sat Dec 25 01:26:18 2010 +0100
@@ -310,7 +310,7 @@
         failed ("cannot read data left in the socket by closed process");
       ASSERT (read (c, buf, 3) == 3);
       ASSERT (write (c, "foo", 3) == 3);
-      ASSERT (close (c) == 0);
+      (void) close (c); /* may fail with errno = ECONNRESET */
     }
 #endif
 }
@@ -354,7 +354,7 @@
   test_pair (c1, c2);
   ASSERT (close (c1) == 0);
   ASSERT (write (c2, "foo", 3) == 3);
-  ASSERT (close (c2) == 0);
+  (void) close (c2); /* may fail with errno = ECONNRESET */
 }