Mail Archives: djgpp/2001/11/15/00:35:35
> However, note that the fragment from the code posted here in the
> beginning of the thread:
>
> if(ioctl(f3,TIOCEXCL)==0 &&
> ioctl(f4,TIOCEXCL)==0){
> lkterm.sg_ispeed = bdrate;
> lkterm.sg_ospeed = bdrate;
> lkterm.sg_erase = ERASECH;
> lkterm.sg_kill = KILLCH;
> lkterm.sg_flags = FLAG;
> if(ioctl(f3,TIOCSETP,&lkterm)!=0 ||
> ioctl(f4,TIOCSETP,&lkterm)!=0){
>
> does suggest that it's not a com port, but an input device such as a
> terminal (otherwise, why set ERASECH and KILLCH?).
Anything that sets baud rate is usually is bad news. The other sets may
be due to terminal driver behavior (those chars are filtered and not sent
in the protocol). If the code explicitly is referencing /dev/tty0 and
setting baud rates ...
If it was a terminal, the code would only work when you are logged into
that one terminal on the system (why do that vs just /dev/tty?)
But it's impossible to know for sure without seeing the entire code and
knowing what it's used for.
- Raw text -