terminal fuckage

Robert Millan zeratul2@wanadoo.es
Mon, 19 Jul 2004 03:45:43 +0200


Hi!

I made some progress on the terminal fuckage thing. This might not be all
of the problem, but at least is part of it. It's certainly what causes gpg
to fail when attempting to read your passphrase, and probably also what
turns the ssh client into madness ('ssh -vvv host' seems to indicate that)

Attempting to open /dev/tty from a virtual terminal (i.e. /dev/ttyv*), does
_always_ fail and errno is set to ENXIO. This won't happen inside screen
because we're using ptys there (/dev/ttyp*). Sample test code:

    int fd;
    fd = open ("/dev/tty", O_RDONLY);
    fprintf (stderr, "errno (%d): %s\n", errno, strerror (errno));
    if (fd != -1)
      close (fd);

I'm currently going through the 2734 instances of ENXIO in the kernel of
FreeBSD, to find out which of them is the faulty one. I expect to find it
in a few days using a simple build&try algorithm =)

-- 
Robert Millan

"[..] but the delight and pride of Aule is in the deed of making, and in the
thing made, and neither in possession nor in his own mastery; wherefore he
gives and hoards not, and is free from care, passing ever on to some new work."

 -- J.R.R.T., Ainulindale (Silmarillion)