|
|
DataMuseum.dkPresents historical artifacts from the history of: DKUUG/EUUG Conference tapes |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about DKUUG/EUUG Conference tapes Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - downloadIndex: T s
Length: 523 (0x20b)
Types: TextFile
Names: »sendbrk.c«
└─⟦a0efdde77⟧ Bits:30001252 EUUGD11 Tape, 1987 Spring Conference Helsinki
└─⟦this⟧ »EUUGD11/euug-87hel/sec8/uutty/sendbrk.c«
#include "uutty.h"
/*
** If fd is a terminal-type device, and ioctl(-,TCSBRK,0) works,
** this will send a break signal down the line, which may (or may
** not) get the attention of whatever is at the other end.
*/
sendbrk(fd)
{ int i;
D4("BREAK");
errno = 0;
D5("sendbrk:before ioctl(fd=%d,TCSBRK=%d,0)",fd,TCSBRK);
i = ioctl(fd,TCSBRK,0);
D5("sendbrk: after ioctl(fd=%d,TCSBRK=%d,0)=%d [errno=%d]",fd,TCSBRK,i,errno);
if (i<0 || errno)
D2("ioctl(%d,TCSBRK=%d,0)=%d\t[errno=%d]",fd,TCSBRK,i,errno);
return i;
}