[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: tty's & pty's
Richard Huveneers <huveneer@math.ruu.nl> writes:
|> The point is that I am trying to port the program "screen 3.5.2" to mint.
|> I run this program on all terminals connected to a sun, and I really like it.
|> The point is, that screen expects pseudo terminals, and as far as I know,
|> mint does not have them.
Of course, MiNT has pseudo terminals, but they are handled quite
differently (i.e. better :-) than under Unix. If you want one, just
create it in the /pipe filesystem:
Fcreate ("u:\\pipe\\name", FA_SYSTEM)
FA_SYSTEM tells the pipe filesystem that this is a pseudo terminal and
it will hand back a handle for the pty master. The next open will
give you a handle for the pty slave. Note that you must use Fcreate
directly to create the pty, with open(2) you cannot pass FA_SYSTEM.
On the other hand, the number of pty's is only limited by the
available memory, and you can give them arbitrary names, as long as
they are in the pipe filesystem. And there is only one name to worry
about. Apart from this, pty's are quite BSD'ish.
--
+------------------------------------------------------------------------+
Andreas Schwab "And now for something
schwab@ls5.informatik.uni-dortmund.de completely different"