Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Test suite failures on GNU Hurd: Test ../../Test/C02cond.ztst failed: bad status 1, expected 0



Hi,

On Tue, Jun 18, 2013 at 09:36:20PM -0700, Bart Schaefer wrote:
> On Jun 19,  1:08am, Axel Beckert wrote:
> } So I wonder: Why does the test suite fail while -c seems to work fine
> } on the command line on GNU Hurd?
> 
> I'm just guessing, but I suspect that because the automated build
> process doesn't have a terminal, then /dev/tty doesn't stat as a char
> device.  Yes, I know that seems unlikely.

We've added a patch which uses the same technique as the -b test case
for finding a suitable tty device:

  find /dev/ -nowarn -maxdepth 1 -name 'tty*' -type c -print

Interestingly that yielded the following error mesage:

  find: `/dev/tty': No such device or address

So it seems to me that if you run a process without controlling
terminal on Hurd, find sees /dev/tty as directory entry, but gets an
error when it tries to stat() it for the "-type c" check.

I was able to prove this theory by connecting to a machine running
Debian GNU/Hurd by ssh but deliberately without a controlling terminal:

% ssh exodar.debian.net "ls -l /dev/" | grep 'tty$'
ls: cannot access /dev/tty: No such device or address
?????????? ? ?    ?       ?            ? tty
% 

This acutally looks like a bug in either libc on Hurd or the Hurd
kernel itself. So it's nothing that zsh should bother (except for the
failing tests of course :-).

> Someone with access to the build could try replacing /dev/tty with
> /dev/zero or /dev/random in that test; if that "fixes" it, then the
> problem is with the implementation of /dev/tty ...

Yes, that'd be my try for the next zsh upload to Debian.

(Actually I wanted to point out here that connecting to a buildd with
SSH gives your a controlling terminal when I remembered that it
doesn't give you a terminal by default if you pass a command as
parameter and suddenly I knew how to test the issue and so you've got
the details above. :-)

		Kind regards, Axel
-- 
/~\  Plain Text Ribbon Campaign                   | Axel Beckert
\ /  Say No to HTML in E-Mail and News            | abe@xxxxxxxxxxxxxxx  (Mail)
 X   See http://www.asciiribbon.org/              | abe@xxxxxxxxx (Mail+Jabber)
/ \  I love long mails: http://email.is-not-s.ms/ | http://noone.org/abe/ (Web)



Messages sorted by: Reverse Date, Date, Thread, Author