PTY-Allocation under SCO 5

Bastian Trompetter btrompetter at firemail.de
Mon Aug 28 17:45:44 EST 2000


Hello,

I used the sshd under SCO 5, and always get the error that the deamon couldn't allcoate a pseudo tty. This depends on that SCO use a different method to create the tty's in the /dev directory. The pseudo tty line looks like:
/dev/ttypXXX where XXX depends on the number of pseudo tty's entered in the scoadmin Tool for the network interface. So I change the allocation routine in the pty.c file from:

snprintf(buf, sizeof buf, "/dev/pty%c%c", ptymajors[i / num_minors],
         ptyminors[i % num_minors]);

snprintf(namebuf, namebuflen, "/dev/tty%c%c",
         ptymajors[i / num_minors], ptyminors[i % num_minors]);

into:

snprintf(buf, sizeof buf, "/dev/ptyp%d", i);

snprintf(namebuf, namebuflen, "/dev/ttyp%d", i);

'i' is set in the for loop. I set 'i' to the maximum of 256.
A possible is to check the system doring the configuration and insert a special define case for SCO in the pty allocation.

I tested the change and it worked very good.

I have only some problems with the egd.pl it stops the generating of randomness. 

Hope this helps.

regards

Bastian Trompetter
  
___________________________________________________________
http://www.firemail.de - Ihr Briefkasten im Web. Einfach, schnell, sicher.

Lust auf Jetset & weltweite Party?
Können Sie haben - auf der Expo! http://www.expo2000.de





More information about the openssh-unix-dev mailing list