]> Savannah Git Hosting - gnulib.git/commitdiff
getlogin-tests: avoid false failure under cron
authorPádraig Brady <P@draigBrady.com>
Sun, 18 May 2014 01:48:03 +0000 (02:48 +0100)
committerPádraig Brady <P@draigBrady.com>
Sun, 18 May 2014 01:50:54 +0000 (02:50 +0100)
* tests/test-getlogin.c (main): Avoid verifying errnos from ttyname()
since that's not what's under test.  Centos 6 was seen to return
EINVAL for ttyname() when run from cron.

ChangeLog
tests/test-getlogin.c

index 87dec135036766eb6e4239d5eb98afca67c9f4cb..bcd414de9252e1efc8dc6cc7c3ccf6b2b24e1873 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2014-05-18  Pádraig Brady  <P@draigBrady.com>
+
+       getlogin-tests: avoid false failure under cron
+       * tests/test-getlogin.c (main): Avoid verifying errnos from ttyname()
+       since that's not what's under test.  Centos 6 was seen to return
+       EINVAL for ttyname() when run from cron.
+
 2014-05-16  Jim Meyering  <meyering@fb.com>
 
        mbrtowc.m4: fix a comment typo
index 32fd89382bcbe575d9fc3083cc27aade8d101ef9..e18469e847f00c0b8fe09fc5b41ec0c0fcf85491 100644 (file)
@@ -75,8 +75,6 @@ main (void)
     tty = ttyname (STDIN_FILENO);
     if (tty == NULL)
       {
-         ASSERT (errno == ENOTTY);
-
          fprintf (stderr, "Skipping test: stdin is not a tty.\n");
          return 77;
       }