From: arumble@extro.ucc.su.OZ.AU (Anthony Rumble) Subject: PTYP/TTYP programming.. Date: Fri, 14 Aug 1992 10:04:01 GMT
Im sure this is a common problem, but.. i have no information
to help me with this..
I am writing a small client to do something, that uses PTYP/TTYP pairs..
The client opens the ttyp open("/dev/ttyp0", O_RDWR) etc etc
and then fdopen's two streams (one for input, one for output)..
well.. anything that is sent to /dev/ptyp0 for some reason
ends up on the client twice!!?!?!
the client only does this as yet..
while(1)
{
ch = fgetc(datin)l
printf("%c", ch);
}
If in another VT.. I do this echo hello >/dev/ptyp0
I will get
Hello
Hello
I get it twice?!?!
Any ideas..
Thanx in advance
-- Anthony Rumble aka SmilieZ "Anything is possible.. If there is enuf money in it"