Explorar o código

Tests: Do not expect EINTR when sleep is interrupted on GNU/Hurd

Previously `RunCMake.CTestTimeout` failed on GNU/Hurd because the
`sleep` command does not set `errno` to `EINTR` when interrupted by a
signal, which is a Linux-specific feature.
Mattias Ellert hai 1 ano
pai
achega
8f53526dec
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      Tests/RunCMake/CTestTimeout/TestTimeout.c

+ 1 - 1
Tests/RunCMake/CTestTimeout/TestTimeout.c

@@ -45,7 +45,7 @@ int main(void)
 #if defined(_WIN32)
   Sleep((TIMEOUT + 4) * 1000);
 #elif defined(SIGNAL_IGNORE)
-#  if defined(__CYGWIN__) || defined(__sun__)
+#  if defined(__CYGWIN__) || defined(__sun__) || defined(__GNU__)
 #    define ERRNO_IS_EINTR (errno == EINTR || errno == 0)
 #  else
 #    define ERRNO_IS_EINTR (errno == EINTR)