Home | History | Annotate | only in /src/usr.bin/tip
History log of /src/usr.bin/tip
RevisionDateAuthorComments
 1.28 14-Apr-2009  lukem Enable WARNS=4 by default for usr.bin, except for:
awk bdes checknr compile_et error gss hxtool kgetcred kinit
klist ldd less lex locale login m4 man menuc mk_cmds
mklocale msgc openssl rpcgen rpcinfo sdiff spell ssh
string2key telnet tn3270 verify_krb5_conf xlint
 1.27 22-May-2006  dan branches: 1.27.28;
the intention of the whole tip-as-cu thing was to allow tip-as-cu and
have a cu command installed, even when the rest of uucp was removed
via MKUUCP=no. The old uucp-derived cu is no more, and is not
installed in either case.

make it so, by correcting some confusion that had made the non-uucp
tip-as-cu cu conditional on MKUUCP
 1.26 08-Apr-2006  christos branches: 1.26.2;
Include bsd.own.mk; from Jukka Salmi
 1.25 05-Apr-2006  tron Fix "MKUUCP" check so that "cu" installed if "MKUUCP" is not defined.
 1.24 04-Apr-2006  dyoung If MKUUCP=no, do not create links for cu and its manual page.
 1.23 03-Apr-2006  yamt fix a typo in LINKS.
 1.22 03-Apr-2006  perry Clean up a bit.
 1.21 03-Apr-2006  perry Remove vestiges of the ACULOG support. It depended on the suid support
(which is now gone) and it is woefully obsolete -- if something
analogous is ever needed in the future, syslog is the way to do it.
 1.20 03-Apr-2006  tls Now we use tip-as-cu, not Taylor UUCP cu.

These programs are no longer setuid, and now lock devices with flock,
not file locks in /var/spool/. They will no longer lock against UUCP
itself unless we modify UUCP to lock with flock, but this seems highly
unlikely to be an issue in the present day.
 1.19 03-Apr-2006  tls The ~C / ~+ command is no longer optional.
 1.18 03-Apr-2006  perry Remove support for uucp style locking.

This means we can get rid of the suid/sgid parts of the code (which
have been removed). The program is now installed with normal permissions.

To prevent accidents, we now flock the tty line, attempting to get an
exclusive lock.

Reviewed by: tls
 1.17 03-Apr-2006  tls Whoops. We don't *use* log.o, so don't *build* it.
 1.16 02-Apr-2006  tls Fix the conditional compilation on ACULOG so it actually works.
Turn it off by default -- it hardly saves any space, but it's
one of the reasons why the executable is installed setuid, and
other versions of tip/cu don't write a log file anyway. We can
add syslog support later if we ever really want this back, the
file-writing is all encapsulated in log.c.
 1.15 02-Apr-2006  tls Don't build any of the dialers except Hayes. If anyone is using any of
the others (maybe "Courier", but I doubt it) we can easily enough turn
them back on.

Saves 20-30K depending on platform. Not totally insignificant, since this
often goes on install media, or very small systems.
 1.14 02-Apr-2006  tls Default baud rate to 9600 (was 1200) to match Taylor cu.
 1.13 16-Mar-2006  christos warns=4
 1.12 23-Apr-2004  christos constify and warns = 3
 1.11 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.10 24-Oct-1997  lukem use CPPFLAGS instead of CFLAGS
 1.9 20-Oct-1997  mrg branches: 1.9.2;
disable WARNS here for now.
 1.8 11-Oct-1997  mycroft Make these executables world-readable.
 1.7 08-May-1997  gwr Back out the .PATH.c changes. The .depend problem (and others)
will be fixed using the new .NOPATH make feature instead.
 1.6 06-May-1997  gwr Use .PATH.c: ...
 1.5 29-Dec-1996  cgd add -ansi -pedantic to CFLAGS, so that people won't try to use the behaviour
of the old zzhack-access macros, which with the current macro definitions
would cause a cast value to be used as an lvalue, which is a gcc extension,
but _not_ what we want.
 1.4 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.3 04-Aug-1993  jtc We're have a real cu now, so break the link between cu and tip.
 1.2 30-Jul-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.9.2.1 08-Nov-1997  lukem sync with trunk (approved by thorpej)
 1.26.2.1 19-Jun-2006  chap Sync with head.
 1.27.28.1 13-May-2009  jym Sync with HEAD.

Third (and last) commit. See http://mail-index.netbsd.org/source-changes/2009/05/13/msg221222.html
 1.3 03-Apr-2006  perry Remove vestiges of the ACULOG support. It depended on the suid support
(which is now gone) and it is woefully obsolete -- if something
analogous is ever needed in the future, syslog is the way to do it.
 1.2 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.1 08-Dec-1994  jtc branches: 1.1.1;
Initial revision
 1.1.1.1 08-Dec-1994  jtc imported from 4.4lite
 1.18 11-Sep-2021  andvar Add missing double p and d for stopped and overriden accordingly.
Fix few more typos along the way, mainly in copy-pasted comments.
 1.17 01-Feb-2019  mrg compare pointers with NULL not '\0'.
 1.16 06-Sep-2011  joerg branches: 1.16.42;
Use __dead. Make a bunch of local functions static.
 1.15 14-Dec-2006  christos pass lint; from Anon Ymous
 1.14 14-Dec-2006  christos kill the (void)&foo; from Anon Ymous
 1.13 24-Oct-2006  gson Added volatile keyword to variable that might be clobbered by longjmp
 1.12 03-Apr-2006  perry Remove vestiges of the ACULOG support. It depended on the suid support
(which is now gone) and it is woefully obsolete -- if something
analogous is ever needed in the future, syslog is the way to do it.
 1.11 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.10 02-Apr-2006  tls Fix the conditional compilation on ACULOG so it actually works.
Turn it off by default -- it hardly saves any space, but it's
one of the reasons why the executable is installed setuid, and
other versions of tip/cu don't write a log file anyway. We can
add syslog support later if we ever really want this back, the
file-writing is all encapsulated in log.c.
 1.9 23-Apr-2004  christos constify and warns = 3
 1.8 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.7 12-Jul-1998  mrg - KNF
- use snprintf
- be safe with buffers (change prompt() to take a size_t len arg for this)
 1.6 30-Jun-1998  thorpej Rename an internal function who's name collides w/ pwrite(2).
 1.5 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.4 29-Dec-1996  cgd replace old zzhack structure (YUCK!) and number(), boolean(), character(),
and address() macros with new macros of the same names (to get values),
and macros with those names but with "set" prepended and which take a
second argument (to set values). The new macros use type casts to do
type conversion, which is much cleaner than using a union and making
endianness-related hacks to get the right 'short's and 'char's from
the right array indices. (YUCK! again, for good measure.)
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.16.42.1 10-Jun-2019  christos Sync with HEAD
 1.5 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.4 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.37 12-Jul-2014  mlelstv don't enable IXANY.
 1.36 02-Jun-2013  christos branches: 1.36.4;
PR/47877: Michael van Elst: Disable and enable software flow control properly
 1.35 24-Feb-2012  joerg branches: 1.35.2;
Add explicit continue to empty loop body.
 1.34 23-Feb-2012  joerg while (...);
;
is really pointless, so remove the first semicolon.
 1.33 06-Sep-2011  joerg branches: 1.33.2;
Use __dead. Make a bunch of local functions static.
 1.32 14-Dec-2006  christos pass lint; from Anon Ymous
 1.31 14-Dec-2006  christos kill the (void)&foo; from Anon Ymous
 1.30 22-Oct-2006  christos sprinkle volatile.
 1.29 11-May-2006  mrg end the argument list to exec*(3) with a NULL instead of a bare '0', as
the latter isn't a pointer context in these varargs functions.
 1.28 03-Apr-2006  tls Use closefrom, don't iterate over file descriptors from 3 to 20.
 1.27 03-Apr-2006  tls Replace abuse of SIGIOT, SIGEMT, SIGSYS for communication between the
TIPIN and TIPOUT processes with a third "attention" pipe. While we're
here, fix a few other minor nits like the hardcoded use of fd 3 in
consh().

Now ~+/~C appear to work. This must have been broken for years.
 1.26 03-Apr-2006  christos Redo the previous in the tip sanctioned way :-)
 1.25 03-Apr-2006  he For the benefit of our 64-bit ports, we need to cast via intptr_t when
casting from pointer to unsigned int.
 1.24 03-Apr-2006  christos Pass a little lint.
 1.23 03-Apr-2006  perry delinting. more needed. (lint found some real bugs that I haven't fixed yet.)
 1.22 03-Apr-2006  tls The ~C / ~+ command is no longer optional.
 1.21 03-Apr-2006  perry Remove support for uucp style locking.

This means we can get rid of the suid/sgid parts of the code (which
have been removed). The program is now installed with normal permissions.

To prevent accidents, we now flock the tty line, attempting to get an
exclusive lock.

Reviewed by: tls
 1.20 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.19 02-Apr-2006  tls Oddly enough, smashing CRTSCTS into the terminal input flags doesn't do
much; it is a control flag.

Now toggling hardware flow control works.
 1.18 02-Apr-2006  tls If we might have two links, we'd better print our program name when we
emit an error -- and it would be nice if it were the *right* program name.
Since it's convenient, change most perror calls to warn, and a lot of
fprintf ... exit to errx. Fix at least one fprintf that could run off
the end of its arguments (%s but no argument, how did we never catch this?).
 1.17 29-Mar-2006  yamt pull the following change from OpenBSD
and bump date of the manpage.

date: 2003/09/20 18:15:32; author: millert; state: Exp; lines: +4 -2
Implement hardwareflow varable in tip(1) like Solaris and hf in /etc/remote.
Based on PR 3411 from Matthew Gream
Also document "tandem" variable (XON/XOFF) in tip man page.
 1.16 23-Apr-2004  christos constify and warns = 3
 1.15 11-Mar-2004  uebayasi getfl() and cu_take() write a file locally. Open a file with O_RDWR.
 1.14 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.13 19-Dec-1998  christos creat->open O_CREAT
 1.12 25-Aug-1998  ross Add { and } to shut up egcs. Reformat the more questionable code.
 1.11 12-Jul-1998  mrg - KNF
- use snprintf
- be safe with buffers (change prompt() to take a size_t len arg for this)
 1.10 30-Jun-1998  thorpej Rename an internal function who's name collides w/ pwrite(2).
 1.9 22-Nov-1997  lukem * fix a long-term annoyance with tip: if raisechar or force are set to
"", (usually in .tiprc with lines like `raisechar='), don't activate
feature if NUL (\0) is the received character
* on a related note, don't barf if the following variables are defined
to "": disconnect, log, parity, record
 1.8 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.7 11-Feb-1997  mrg give buffers lengths; use strdup.
 1.6 29-Oct-1995  pk Convert to termios (from Scott Reynolds; PR#1621).
8-bit patches (from Matthieu Herrb; PR#1384).
 1.5 26-Sep-1995  jtc Fix crash with null eofwrite capabilityand lseek/off_t bug; PR #1346
 1.4 24-Dec-1994  cgd headers, casts, and use of time_t
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.33.2.2 22-May-2014  yamt sync with head.

for a reference, the tree before this commit was tagged
as yamt-pagecache-tag8.

this commit was splitted into small chunks to avoid
a limitation of cvs. ("Protocol error: too many arguments")
 1.33.2.1 17-Apr-2012  yamt sync with head
 1.35.2.2 20-Aug-2014  tls Rebase to HEAD as of a few days ago.
 1.35.2.1 23-Jun-2013  tls resync from head
 1.36.4.1 10-Aug-2014  tls Rebase.
 1.8 22-Oct-2006  christos use c99 initializer.
 1.7 03-Apr-2006  tls The ~C / ~+ command is no longer optional.
 1.6 02-Apr-2006  tls Add "~+" as a synonym for "~C" for Taylor cu compatibility.
 1.5 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.4 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.25 03-Nov-2024  rillig sbin, usr.bin, usr.sbin: remove redundant getopt declarations

No binary change, except for assertion line numbers in tprof.
 1.24 18-Aug-2019  christos branches: 1.24.10;
check speed argument conversion (Thierry Laronde)
 1.23 03-Jan-2016  christos branches: 1.23.16;
Put back -n
 1.22 27-Jul-2014  dholland Remove broken snprintf usage (noted in PR 47976) and replace with
something simpler.
 1.21 06-Sep-2011  joerg branches: 1.21.8; 1.21.18;
Use __dead. Make a bunch of local functions static.
 1.20 14-Dec-2006  christos pass lint; from Anon Ymous
 1.19 29-Nov-2006  jdc Add Taylor cu compatibility: -f and "dir"
 1.18 05-Apr-2006  yamt cuhelp: fix a typo in usage.
 1.17 03-Apr-2006  christos Pass a little lint.
 1.16 03-Apr-2006  perry Remove vestiges of the ACULOG support. It depended on the suid support
(which is now gone) and it is woefully obsolete -- if something
analogous is ever needed in the future, syslog is the way to do it.
 1.15 03-Apr-2006  perry Remove support for uucp style locking.

This means we can get rid of the suid/sgid parts of the code (which
have been removed). The program is now installed with normal permissions.

To prevent accidents, we now flock the tty line, attempting to get an
exclusive lock.

Reviewed by: tls
 1.14 03-Apr-2006  tls If we're not given a phone number or system name to dial, use "direct
connect" mode -- in other words, set CLOCAL so the user can talk to the
device before CD.
 1.13 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.12 02-Apr-2006  tls Add another Taylor compat option, --nostop to disable software flow control
(a.k.a. "tandem" mode). While we're here, fix a buglet with --halfduplex,
and add --flow {hard, soft, none}. Note that you can't get *both* hard and
soft flow control using the command-line option; if you want that, you
have to set the variables in tiprc or with ~s once tip is running.

Move all setting of vars.c named variables to *after* the call to vinit().
 1.11 02-Apr-2006  tls Fix the conditional compilation on ACULOG so it actually works.
Turn it off by default -- it hardly saves any space, but it's
one of the reasons why the executable is installed setuid, and
other versions of tip/cu don't write a log file anyway. We can
add syslog support later if we ever really want this back, the
file-writing is all encapsulated in log.c.
 1.10 02-Apr-2006  tls New 'cu' command-line handling, derived from Todd Miller's in OpenBSD,
but with some long options added for Taylor 'cu' compatibility, and
with some bugs fixed (in particular, the handling of -# now works as
documented and does not overwrite argv).
 1.9 02-Apr-2006  tls If we might have two links, we'd better print our program name when we
emit an error -- and it would be nice if it were the *right* program name.
Since it's convenient, change most perror calls to warn, and a lot of
fprintf ... exit to errx. Fix at least one fprintf that could run off
the end of its arguments (%s but no argument, how did we never catch this?).
 1.8 16-Mar-2006  christos warns=4
 1.7 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.6 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.5 11-Feb-1997  mrg give buffers lengths; use strdup.
 1.4 29-Dec-1996  cgd replace old zzhack structure (YUCK!) and number(), boolean(), character(),
and address() macros with new macros of the same names (to get values),
and macros with those names but with "set" prepended and which take a
second argument (to set values). The new macros use type casts to do
type conversion, which is much cleaner than using a union and making
endianness-related hacks to get the right 'short's and 'char's from
the right array indices. (YUCK! again, for good measure.)
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.21.18.1 10-Aug-2014  tls Rebase.
 1.21.8.1 20-Aug-2014  tls Rebase to HEAD as of a few days ago.
 1.23.16.1 13-Apr-2020  martin Mostly merge changes from HEAD upto 20200411
 1.24.10.1 02-Aug-2025  perseant Sync with HEAD
 1.18 06-Sep-2011  joerg Use __dead. Make a bunch of local functions static.
 1.17 24-May-2011  joerg Properly use format string
 1.16 14-Dec-2006  christos pass lint; from Anon Ymous
 1.15 30-Apr-2006  christos Coverity CID 2972, 2973: Don't call close() with a negative fd.
 1.14 03-Apr-2006  christos Pass a little lint.
 1.13 03-Apr-2006  perry Remove support for uucp style locking.

This means we can get rid of the suid/sgid parts of the code (which
have been removed). The program is now installed with normal permissions.

To prevent accidents, we now flock the tty line, attempting to get an
exclusive lock.

Reviewed by: tls
 1.12 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.11 02-Apr-2006  tls If we might have two links, we'd better print our program name when we
emit an error -- and it would be nice if it were the *right* program name.
Since it's convenient, change most perror calls to warn, and a lot of
fprintf ... exit to errx. Fix at least one fprintf that could run off
the end of its arguments (%s but no argument, how did we never catch this?).
 1.10 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.9 12-Jul-1998  mrg - KNF
- use snprintf
- be safe with buffers (change prompt() to take a size_t len arg for this)
 1.8 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.7 14-May-1997  mellon DC is not a user-settable variable, but was being partially confused with one
 1.6 20-Apr-1997  mellon Set O_NONBLOCK if dc flag is set. Don't set HUPCL if dc flag is set.
 1.5 29-Oct-1995  pk Convert to termios (from Scott Reynolds; PR#1621).
8-bit patches (from Matthieu Herrb; PR#1384).
 1.4 24-Dec-1994  cgd headers, casts, and use of time_t
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.13 03-Apr-2006  perry Remove vestiges of the ACULOG support. It depended on the suid support
(which is now gone) and it is woefully obsolete -- if something
analogous is ever needed in the future, syslog is the way to do it.
 1.12 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.11 02-Apr-2006  tls If we might have two links, we'd better print our program name when we
emit an error -- and it would be nice if it were the *right* program name.
Since it's convenient, change most perror calls to warn, and a lot of
fprintf ... exit to errx. Fix at least one fprintf that could run off
the end of its arguments (%s but no argument, how did we never catch this?).
 1.10 23-Apr-2004  christos constify and warns = 3
 1.9 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.8 25-Aug-1998  ross Add { and } to shut up egcs. Reformat the more questionable code.
 1.7 26-Jul-1998  mycroft const poisoning.
 1.6 22-Nov-1997  lukem * fix a long-term annoyance with tip: if raisechar or force are set to
"", (usually in .tiprc with lines like `raisechar='), don't activate
feature if NUL (\0) is the received character
* on a related note, don't barf if the following variables are defined
to "": disconnect, log, parity, record
 1.5 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.4 24-Dec-1994  cgd headers, casts, and use of time_t
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.6 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.5 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.4 29-Dec-1996  cgd make evenpartab be of type 'unsigned char' to avoid -ansi -pedantic errors
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.5 03-Apr-2006  perry Remove vestiges of the ACULOG support. It depended on the suid support
(which is now gone) and it is woefully obsolete -- if something
analogous is ever needed in the future, syslog is the way to do it.
 1.4 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.6 07-Mar-1996  jtc unused file
 1.5 24-Dec-1994  cgd headers, casts, and use of time_t
 1.4 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.3 01-Aug-1993  mycroft Add RCS identifiers.
 1.2 19-Apr-1993  mycroft Cleanup for GCC 2.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.21 20-Sep-2024  andvar s/gleened/gleaned/ in comment.
 1.20 16-Jun-2015  christos branches: 1.20.28;
fix some error handling.
 1.19 21-Oct-2013  christos get rid of equal(), use {s,g}etprogname().
 1.18 21-Jul-2008  lukem branches: 1.18.2; 1.18.24;
Remove the \n and tabs from the __COPYRIGHT() strings.
Tweak to use a consistent format.
 1.17 14-Dec-2006  christos branches: 1.17.12;
pass lint; from Anon Ymous
 1.16 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.15 02-Apr-2006  tls Fix the conditional compilation on ACULOG so it actually works.
Turn it off by default -- it hardly saves any space, but it's
one of the reasons why the executable is installed setuid, and
other versions of tip/cu don't write a log file anyway. We can
add syslog support later if we ever really want this back, the
file-writing is all encapsulated in log.c.
 1.14 02-Apr-2006  tls Remove extra \n from call to warn()
 1.13 02-Apr-2006  tls If we might have two links, we'd better print our program name when we
emit an error -- and it would be nice if it were the *right* program name.
Since it's convenient, change most perror calls to warn, and a lot of
fprintf ... exit to errx. Fix at least one fprintf that could run off
the end of its arguments (%s but no argument, how did we never catch this?).
 1.12 29-Mar-2006  yamt pull the following change from OpenBSD
and bump date of the manpage.

date: 2003/09/20 18:15:32; author: millert; state: Exp; lines: +4 -2
Implement hardwareflow varable in tip(1) like Solaris and hf in /etc/remote.
Based on PR 3411 from Matthew Gream
Also document "tandem" variable (XON/XOFF) in tip man page.
 1.11 23-Apr-2004  christos deal in a saner way with const strings.
 1.10 23-Apr-2004  christos constify and warns = 3
 1.9 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.8 25-Aug-1998  ross Add { and } to shut up egcs. Reformat the more questionable code.
 1.7 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.6 14-May-1997  mellon DC is not a user-settable variable, but was being partially confused with one
 1.5 20-Apr-1997  mellon Add boolean for dc flag
 1.4 29-Dec-1996  cgd replace old zzhack structure (YUCK!) and number(), boolean(), character(),
and address() macros with new macros of the same names (to get values),
and macros with those names but with "set" prepended and which take a
second argument (to set values). The new macros use type casts to do
type conversion, which is much cleaner than using a union and making
endianness-related hacks to get the right 'short's and 'char's from
the right array indices. (YUCK! again, for good measure.)
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.17.12.1 18-Sep-2008  wrstuden Sync with wrstuden-revivesa-base-2.
 1.18.24.1 20-Aug-2014  tls Rebase to HEAD as of a few days ago.
 1.18.2.1 22-May-2014  yamt sync with head.

for a reference, the tree before this commit was tagged
as yamt-pagecache-tag8.

this commit was splitted into small chunks to avoid
a limitation of cvs. ("Protocol error: too many arguments")
 1.20.28.1 02-Aug-2025  perseant Sync with HEAD
 1.37 26-May-2025  gutteridge tip.1: add missing markup
 1.36 26-May-2025  gutteridge tip.1: amend -P argument parity details
 1.35 26-May-2025  gutteridge tip.1: make some minor amendments

The paragraph about applying both -e and -o has never been correct for
NetBSD's implementation, from code and CVS history inspection. It looks
like it was a pasto from r. 1.26 when various parts of the OpenBSD man
page of the era were merged in.

Add an explanation of what cu(1)'s "dir" argument is for. (Really it's
optional and should be marked that way in the synopsis, but this seems
tricky to do while keeping the markup.)

While here, also borrow a historical note about cu(1) from OpenBSD.
 1.34 25-Apr-2023  gutteridge branches: 1.34.2;
tip.1: s/Mail.1/mail.1/ ("Mail" was removed in 9)
 1.33 03-Jul-2017  wiz Remove workaround for ancient HTML generation code.
 1.32 22-Mar-2012  wiz Fix whitespace nits. Suggested by Bug Hunting.
 1.31 13-Mar-2009  joerg branches: 1.31.6;
Use .Tn for XMODEM. Use .Bl -column for physically marked up table.
 1.30 17-Jan-2009  wiz branches: 1.30.2;
Improve description in NAME section:
"serial terminal emulator"

From nick@openbsd via jmc@openbsd.
 1.29 23-Dec-2006  wiz Punctuation nits.
 1.28 29-Nov-2006  jdc Add missing cu synopsis and options.
 1.27 03-Apr-2006  wiz Use Dq, punctuation vs whitespace nits.
 1.26 03-Apr-2006  perry Merge a few of the OpenBSD manual page changes. Not yet close to
finished but I have to break for now and Thor will probably pick up
from where I left off.
 1.25 03-Apr-2006  perry remove refs to uucp locking and aculog
 1.24 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.23 02-Apr-2006  tls Change manual page (as OpenBSD did) to reflect the actual arrangement of
file descriptors with ~C, instead of some weird ancient arrangement.

Document ~+ as a synonym for ~C.
 1.22 29-Mar-2006  yamt pull the following change from OpenBSD
and bump date of the manpage.

date: 2003/09/20 18:15:32; author: millert; state: Exp; lines: +4 -2
Implement hardwareflow varable in tip(1) like Solaris and hf in /etc/remote.
Based on PR 3411 from Matthew Gream
Also document "tandem" variable (XON/XOFF) in tip man page.
 1.21 09-May-2004  snj English fix.
 1.20 13-Feb-2004  wiz branches: 1.20.2;
Uppercase CPU.
 1.19 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.18 25-Feb-2003  wiz .Nm does not need a dummy argument ("") before punctuation or
for correct formatting of the SYNOPSIS any longer.
 1.17 13-Oct-2002  wiz Comment out a line again.
 1.16 30-Sep-2002  grant New sentence, new line.
 1.15 03-May-2002  mjl s/appeared command/command appeared/
 1.14 08-Feb-2002  ross Generate <>& symbolically. I'm avoiding .../dist/... directories for now.
 1.13 08-Dec-2001  wiz Sort SEE ALSO.
 1.12 04-Apr-2001  wiz Add section to xref. Whitespace fixes.
 1.11 29-May-2000  bjh21 branches: 1.11.2;
Fix missing space
 1.10 22-Mar-1999  garbled branches: 1.10.8;
More and more .Os cleanups. .Os is defined in the tmac.doc-common file,
so we shouldn't override it with versions in the manpages. Many more to
come.
 1.9 06-Mar-1999  mycroft Fix minor formatting error.
 1.8 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.7 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.6 19-Sep-1994  mycroft Make lock directory match the code.
 1.5 11-Jan-1994  jtc Fix spelling errors.
 1.4 04-Aug-1993  jtc We're have a real cu now, so break the link between cu and tip.
 1.3 04-Aug-1993  jtc Fix formatting bug.
 1.2 01-Aug-1993  mycroft Add RCS indentifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.10.8.1 23-Jun-2000  minoura Sync w/ netbsd-1-5-base.
 1.11.2.1 26-Apr-2001  he Pull up revision 1.12 (requested by wiz):
Add section to cross references, and whitespace fixes.
 1.20.2.1 11-May-2004  tron Pull up revision 1.21 (requested by snj in ticket #299):
English fix.
 1.30.2.1 13-May-2009  jym Sync with HEAD.

Third (and last) commit. See http://mail-index.netbsd.org/source-changes/2009/05/13/msg221222.html
 1.31.6.1 17-Apr-2012  yamt sync with head
 1.34.2.1 02-Aug-2025  perseant Sync with HEAD
 1.63 23-Apr-2020  joerg Avoid using common symbol definitions.
 1.62 28-Feb-2019  gson Make xgetchar() return an int like getchar() does, and remove needless cast.
 1.61 22-Feb-2019  uwe Check getchar() result for EOF.

Call cleanup(SIGHUP) if we get local EOF, as if we've got SIGHUP.
While here, use EOF constant instead of literal -1 in an existing
check.

PR bin/53996
 1.60 06-Feb-2019  rin Make cu(1) and tip(1) recognize newline (^J) as end-of-line.
Now, tilde (~) after newline works as escape character as in ssh(1).
No objections when proposed on tech-userland.
 1.59 05-Sep-2016  sevan branches: 1.59.14;
Drop main() prototype.
 1.58 17-Jun-2015  christos add missing quote, remove some braces.
 1.57 16-Jun-2015  christos fix some error handling.
 1.56 11-Jun-2015  gson Don't call exit() from a signal handler, as it's not async-signal-safe;
use _exit() instead.
 1.55 27-Jul-2014  dholland Remove broken snprintf usage (noted in PR 47976) and replace with
something simpler.
 1.54 12-Jul-2014  mlelstv don't enable IXANY.
 1.53 21-Oct-2013  christos branches: 1.53.2;
get rid of equal(), use {s,g}etprogname().
 1.52 02-Jun-2013  christos PR/47877: Michael van Elst: Disable and enable software flow control properly
 1.51 06-Sep-2011  joerg branches: 1.51.2; 1.51.8;
Use __dead. Make a bunch of local functions static.
 1.50 18-Jan-2009  lukem fix -Wsign-compare issues
 1.49 21-Jul-2008  lukem Remove the \n and tabs from the __COPYRIGHT() strings.
Tweak to use a consistent format.
 1.48 09-Mar-2007  hubertf branches: 1.48.12;
Move #include <libgen.h> from tip.h to the place where it's really needed.
From: Slava Semushin <php-coder@altlinux.ru>
 1.47 16-Feb-2007  hubertf Moved ctype.h from header to source file in usr.bin/tip.
Also removed unused getopt header.

Patch contributed by Slava Semushin <slava.semushin@gmail.com>
in private mail.
 1.46 14-Dec-2006  christos pass lint; from Anon Ymous
 1.45 14-Dec-2006  christos kill the (void)&foo; from Anon Ymous
 1.44 29-Nov-2006  jdc Use getopt() for arguments. Suggested by tls@.
 1.43 03-Apr-2006  tls Use closefrom, don't iterate over file descriptors from 3 to 20.
 1.42 03-Apr-2006  tls Replace abuse of SIGIOT, SIGEMT, SIGSYS for communication between the
TIPIN and TIPOUT processes with a third "attention" pipe. While we're
here, fix a few other minor nits like the hardcoded use of fd 3 in
consh().

Now ~+/~C appear to work. This must have been broken for years.
 1.41 03-Apr-2006  tls Move "cucommon" label (ugh) to above the O_NONBLOCK handling for direct
connections. This stops the tipout process from spinning.
 1.40 03-Apr-2006  yamt actually set up baudrate after rev.1.33.
 1.39 03-Apr-2006  christos Pass a little lint.
 1.38 03-Apr-2006  perry delinting. more needed. (lint found some real bugs that I haven't fixed yet.)
 1.37 03-Apr-2006  perry Remove vestiges of the ACULOG support. It depended on the suid support
(which is now gone) and it is woefully obsolete -- if something
analogous is ever needed in the future, syslog is the way to do it.
 1.36 03-Apr-2006  perry Remove support for uucp style locking.

This means we can get rid of the suid/sgid parts of the code (which
have been removed). The program is now installed with normal permissions.

To prevent accidents, we now flock the tty line, attempting to get an
exclusive lock.

Reviewed by: tls
 1.35 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.34 02-Apr-2006  tls Fix the conditional compilation on ACULOG so it actually works.
Turn it off by default -- it hardly saves any space, but it's
one of the reasons why the executable is installed setuid, and
other versions of tip/cu don't write a log file anyway. We can
add syslog support later if we ever really want this back, the
file-writing is all encapsulated in log.c.
 1.33 02-Apr-2006  tls New 'cu' command-line handling, derived from Todd Miller's in OpenBSD,
but with some long options added for Taylor 'cu' compatibility, and
with some bugs fixed (in particular, the handling of -# now works as
documented and does not overwrite argv).
 1.32 02-Apr-2006  tls If we might have two links, we'd better print our program name when we
emit an error -- and it would be nice if it were the *right* program name.
Since it's convenient, change most perror calls to warn, and a lot of
fprintf ... exit to errx. Fix at least one fprintf that could run off
the end of its arguments (%s but no argument, how did we never catch this?).
 1.31 02-Apr-2006  tls Default to no parity instead of even parity. OpenBSD made this change
long ago, and I think it makes sense.
 1.30 02-Apr-2006  tls Add the rest of the speeds listed in termios.h. This is not, perhaps, as
sensible as the way OpenBSD supports arbitrary speeds; but we hardly add
new speeds often and this change is a lot less invasive.
 1.29 29-Mar-2006  yamt pull the following change from OpenBSD
and bump date of the manpage.

date: 2003/09/20 18:15:32; author: millert; state: Exp; lines: +4 -2
Implement hardwareflow varable in tip(1) like Solaris and hf in /etc/remote.
Based on PR 3411 from Matthew Gream
Also document "tandem" variable (XON/XOFF) in tip man page.
 1.28 04-Nov-2004  dsl Add (unsigned char) cast to ctype functions
islower() can be true for 0x80..0xff
 1.27 07-Sep-2004  jrf Replaced strncpy with strlcpy. Thanks to Peter Postma who
pointed them our in PR #25762. Approved by christos@NetBSD.org.
 1.26 23-Apr-2004  christos deal in a saner way with const strings.
 1.25 23-Apr-2004  christos constify and warns = 3
 1.24 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.23 11-Oct-2000  is More format string cleanup by sommerfeld.
 1.22 19-Dec-1998  christos branches: 1.22.2; 1.22.10;
remove unused variable
char -> unsigned char
 1.21 12-Jul-1998  mrg - KNF
- use snprintf
- be safe with buffers (change prompt() to take a size_t len arg for this)
 1.20 30-Jun-1998  thorpej Rename an internal function who's name collides w/ pwrite(2).
 1.19 17-Dec-1997  mellon Only turn off the O_NONBLOCK flag if DC flag is set.
 1.18 17-Dec-1997  mellon Turn off the O_NONBLOCK flag after CLOCAL is set.
 1.17 23-Nov-1997  mrg fix compile warnings on the alpha.
 1.16 22-Nov-1997  lukem * fix a long-term annoyance with tip: if raisechar or force are set to
"", (usually in .tiprc with lines like `raisechar='), don't activate
feature if NUL (\0) is the received character
* on a related note, don't barf if the following variables are defined
to "": disconnect, log, parity, record
 1.15 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.14 14-May-1997  mellon branches: 1.14.2;
DC is not a user-settable variable, but was being partially confused with one
 1.13 20-Apr-1997  mellon Set CLOCAL if dc flag is set
 1.12 19-Apr-1997  thorpej getopt() returns:
- an int, not a char, and
- -1 upon completion, not EOF.
 1.11 11-Feb-1997  mrg give buffers lengths; use strdup.
 1.10 29-Dec-1996  cgd make evenpartab be of type 'unsigned char' to avoid -ansi -pedantic errors
 1.9 29-Dec-1996  cgd replace old zzhack structure (YUCK!) and number(), boolean(), character(),
and address() macros with new macros of the same names (to get values),
and macros with those names but with "set" prepended and which take a
second argument (to set values). The new macros use type casts to do
type conversion, which is much cleaner than using a union and making
endianness-related hacks to get the right 'short's and 'char's from
the right array indices. (YUCK! again, for good measure.)
 1.8 29-Oct-1995  pk Convert to termios (from Scott Reynolds; PR#1621).
8-bit patches (from Matthieu Herrb; PR#1384).
 1.7 11-Aug-1995  jtc Fix parity calculation; PR #1325
 1.6 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.5 20-Apr-1994  pk setre[gu]id conversion.
 1.4 01-Aug-1993  mycroft Add RCS identifiers.
 1.3 12-Jun-1993  andrew Flip euid to user immediately after opening log file, to allow .tiprc file
to be read without perms problems.
 1.2 05-Jun-1993  cgd patch from David Greenman and Rod Grimes (davidg@implode.rain.com and
rgrimes@agora.rain.com) to support 57600 and 115200 baud
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.14.2.1 17-Dec-1997  mellon Pull rev 1.18 and 1.19 up from trunk (mellon) (reviewed by mycroft and thorpej)
 1.22.10.1 18-Oct-2000  tv Pullup usr.bin string format fixes [is].
See "cvs log" for explicit revision numbers per file, from sommerfeld.
 1.22.2.1 19-Oct-2000  he Pull up revision 1.23 (requested by he):
Format string cleanup.
 1.48.12.1 18-Sep-2008  wrstuden Sync with wrstuden-revivesa-base-2.
 1.51.8.2 20-Aug-2014  tls Rebase to HEAD as of a few days ago.
 1.51.8.1 23-Jun-2013  tls resync from head
 1.51.2.1 22-May-2014  yamt sync with head.

for a reference, the tree before this commit was tagged
as yamt-pagecache-tag8.

this commit was splitted into small chunks to avoid
a limitation of cvs. ("Protocol error: too many arguments")
 1.53.2.1 10-Aug-2014  tls Rebase.
 1.59.14.1 10-Jun-2019  christos Sync with HEAD
 1.37 22-May-2022  andvar fix various small typos, mainly in comments.
 1.36 24-Jan-2022  andvar s/begining/beginning/ in comments and messages.
 1.35 10-Sep-2021  rillig usr.bin: remove unnecessary lint comment CONSTCOND

Since 2021-01-31, lint no longer warns about 'do ... while (0)'.

No functional change.
 1.34 23-Apr-2020  joerg Avoid using common symbol definitions.
 1.33 21-Oct-2013  christos get rid of equal(), use {s,g}etprogname().
 1.32 06-Sep-2011  joerg branches: 1.32.2; 1.32.8;
Use __dead. Make a bunch of local functions static.
 1.31 28-Jan-2010  mbalmer fix language
 1.30 09-Mar-2007  hubertf Move #include <libgen.h> from tip.h to the place where it's really needed.
From: Slava Semushin <php-coder@altlinux.ru>
 1.29 16-Feb-2007  hubertf Moved ctype.h from header to source file in usr.bin/tip.
Also removed unused getopt header.

Patch contributed by Slava Semushin <slava.semushin@gmail.com>
in private mail.
 1.28 14-Dec-2006  christos pass lint; from Anon Ymous
 1.27 03-Apr-2006  tls Use closefrom, don't iterate over file descriptors from 3 to 20.
 1.26 03-Apr-2006  tls Replace abuse of SIGIOT, SIGEMT, SIGSYS for communication between the
TIPIN and TIPOUT processes with a third "attention" pipe. While we're
here, fix a few other minor nits like the hardcoded use of fd 3 in
consh().

Now ~+/~C appear to work. This must have been broken for years.
 1.25 03-Apr-2006  christos Pass a little lint.
 1.24 03-Apr-2006  perry delinting. more needed. (lint found some real bugs that I haven't fixed yet.)
 1.23 03-Apr-2006  tls Wwwwwwww! Do not remove variables from the vtable in vars.c without
changing the indices in tip.h -- what a terrible design.

Okay, "design". Fine. Whatever. ;-) Now we don't dump core all the time.
 1.22 03-Apr-2006  perry Remove vestiges of the ACULOG support. It depended on the suid support
(which is now gone) and it is woefully obsolete -- if something
analogous is ever needed in the future, syslog is the way to do it.
 1.21 03-Apr-2006  perry Remove support for uucp style locking.

This means we can get rid of the suid/sgid parts of the code (which
have been removed). The program is now installed with normal permissions.

To prevent accidents, we now flock the tty line, attempting to get an
exclusive lock.

Reviewed by: tls
 1.20 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.19 02-Apr-2006  tls Fix the conditional compilation on ACULOG so it actually works.
Turn it off by default -- it hardly saves any space, but it's
one of the reasons why the executable is installed setuid, and
other versions of tip/cu don't write a log file anyway. We can
add syslog support later if we ever really want this back, the
file-writing is all encapsulated in log.c.
 1.18 02-Apr-2006  tls New 'cu' command-line handling, derived from Todd Miller's in OpenBSD,
but with some long options added for Taylor 'cu' compatibility, and
with some bugs fixed (in particular, the handling of -# now works as
documented and does not overwrite argv).
 1.17 29-Mar-2006  yamt pull the following change from OpenBSD
and bump date of the manpage.

date: 2003/09/20 18:15:32; author: millert; state: Exp; lines: +4 -2
Implement hardwareflow varable in tip(1) like Solaris and hf in /etc/remote.
Based on PR 3411 from Matthew Gream
Also document "tandem" variable (XON/XOFF) in tip man page.
 1.16 23-Apr-2004  christos constify and warns = 3
 1.15 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.14 08-Jul-2001  wiz synchron*, not sychron*
 1.13 16-Aug-1999  simonb Spell "privilege" correctly (correct spelling from Jonathan Stone).
 1.12 19-Dec-1998  christos <sys/dir.h> -> <dirent.h>
<sys/file.h> -> <fcntl.h>
 1.11 12-Jul-1998  mrg - KNF
- use snprintf
- be safe with buffers (change prompt() to take a size_t len arg for this)
 1.10 30-Jun-1998  thorpej Rename an internal function who's name collides w/ pwrite(2).
 1.9 02-Apr-1998  kleink Include <time.h>, needed for various definitions. Also, per KNF, don't include
both <sys/param.h> and <sys/types.h>; the former is sufficient.
 1.8 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.7 20-Apr-1997  mellon Add boolean for dc flag
 1.6 19-Apr-1997  thorpej Change booleans from char to int so that comparisons against negative
values work as expected on systems with unsigned chars.
 1.5 29-Dec-1996  cgd replace old zzhack structure (YUCK!) and number(), boolean(), character(),
and address() macros with new macros of the same names (to get values),
and macros with those names but with "set" prepended and which take a
second argument (to set values). The new macros use type casts to do
type conversion, which is much cleaner than using a union and making
endianness-related hacks to get the right 'short's and 'char's from
the right array indices. (YUCK! again, for good measure.)
 1.4 29-Oct-1995  pk Convert to termios (from Scott Reynolds; PR#1621).
8-bit patches (from Matthieu Herrb; PR#1384).
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.32.8.1 20-Aug-2014  tls Rebase to HEAD as of a few days ago.
 1.32.2.1 22-May-2014  yamt sync with head.

for a reference, the tree before this commit was tagged
as yamt-pagecache-tag8.

this commit was splitted into small chunks to avoid
a limitation of cvs. ("Protocol error: too many arguments")
 1.15 06-Sep-2011  joerg Use __dead. Make a bunch of local functions static.
 1.14 14-Dec-2006  christos pass lint; from Anon Ymous
 1.13 03-Apr-2006  tls Use closefrom, don't iterate over file descriptors from 3 to 20.
 1.12 03-Apr-2006  tls Replace abuse of SIGIOT, SIGEMT, SIGSYS for communication between the
TIPIN and TIPOUT processes with a third "attention" pipe. While we're
here, fix a few other minor nits like the hardcoded use of fd 3 in
consh().

Now ~+/~C appear to work. This must have been broken for years.
 1.11 03-Apr-2006  christos Pass a little lint.
 1.10 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.9 09-Dec-2005  gavan Treat EOF the same as EIO. Prevents spinning if an EOF condition is
encountered, such as a USB serial device being unplugged.

Instead of spinning, the process reading from the serial line will exit,
leaving the process reading from the local terminal to exit when it notices
that its child has gone away.
 1.8 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.7 12-Jul-1998  mrg - KNF
- use snprintf
- be safe with buffers (change prompt() to take a size_t len arg for this)
 1.6 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.5 29-Dec-1996  cgd replace old zzhack structure (YUCK!) and number(), boolean(), character(),
and address() macros with new macros of the same names (to get values),
and macros with those names but with "set" prepended and which take a
second argument (to set values). The new macros use type casts to do
type conversion, which is much cleaner than using a union and making
endianness-related hacks to get the right 'short's and 'char's from
the right array indices. (YUCK! again, for good measure.)
 1.4 29-Oct-1995  pk Convert to termios (from Scott Reynolds; PR#1621).
8-bit patches (from Matthieu Herrb; PR#1384).
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.15 03-Apr-2006  perry Remove support for uucp style locking.

This means we can get rid of the suid/sgid parts of the code (which
have been removed). The program is now installed with normal permissions.

To prevent accidents, we now flock the tty line, attempting to get an
exclusive lock.

Reviewed by: tls
 1.14 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.13 02-Apr-2006  tls If we might have two links, we'd better print our program name when we
emit an error -- and it would be nice if it were the *right* program name.
Since it's convenient, change most perror calls to warn, and a lot of
fprintf ... exit to errx. Fix at least one fprintf that could run off
the end of its arguments (%s but no argument, how did we never catch this?).
 1.12 23-Apr-2004  christos constify and warns = 3
 1.11 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.10 12-Jul-1998  mrg - KNF
- use snprintf
- be safe with buffers (change prompt() to take a size_t len arg for this)
 1.9 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.8 25-Aug-1997  kleink Lseek(2) usage cleanup: the use of L_SET/L_INCR/L_XTND is deprecated,
use SEEK_SET/SEEK_CUR/SEEK_END instead.
 1.7 11-Feb-1997  mrg give buffers lengths; use strdup.
 1.6 26-Sep-1995  jtc Fix crash with null eofwrite capabilityand lseek/off_t bug; PR #1346
 1.5 24-Dec-1994  cgd headers, casts, and use of time_t
 1.4 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.3 01-Aug-1993  mycroft Add RCS identifiers.
 1.2 05-Jun-1993  cgd Peter da Silva's <peter@taronga.com> for tip to obey the
taylor UUCP locking convention
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.15 21-Oct-2013  christos get rid of equal(), use {s,g}etprogname().
 1.14 14-Dec-2006  christos branches: 1.14.34; 1.14.40;
pass lint; from Anon Ymous
 1.13 03-Apr-2006  christos Pass a little lint.
 1.12 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.11 23-Apr-2004  christos constify and warns = 3
 1.10 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.9 12-Jul-1998  mrg - KNF
- use snprintf
- be safe with buffers (change prompt() to take a size_t len arg for this)
 1.8 23-Nov-1997  mrg fix compile warnings on the alpha.
 1.7 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.6 11-Feb-1997  mrg give buffers lengths; use strdup.
 1.5 29-Dec-1996  cgd fix up -ansi -pedantic warnings produced because of static function
declarations nested in other functions. The solution: declare the
static functions at the top level.
 1.4 29-Dec-1996  cgd replace old zzhack structure (YUCK!) and number(), boolean(), character(),
and address() macros with new macros of the same names (to get values),
and macros with those names but with "set" prepended and which take a
second argument (to set values). The new macros use type casts to do
type conversion, which is much cleaner than using a union and making
endianness-related hacks to get the right 'short's and 'char's from
the right array indices. (YUCK! again, for good measure.)
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.14.40.1 20-Aug-2014  tls Rebase to HEAD as of a few days ago.
 1.14.34.1 22-May-2014  yamt sync with head.

for a reference, the tree before this commit was tagged
as yamt-pagecache-tag8.

this commit was splitted into small chunks to avoid
a limitation of cvs. ("Protocol error: too many arguments")
 1.12 03-Apr-2006  christos Pass a little lint.
 1.11 03-Apr-2006  perry Remove vestiges of the ACULOG support. It depended on the suid support
(which is now gone) and it is woefully obsolete -- if something
analogous is ever needed in the future, syslog is the way to do it.
 1.10 02-Apr-2006  tls At Luke Mewburn's suggestion, disable "force" by default, too. Those using
the tip frontend who really want ^P used for "send literal" can turn it on
in tiprc or remote.
 1.9 02-Apr-2006  tls Default the "raisechar" value (for the insane old case-mapping) to NULL.
As the same change in the OpenBSD tree says, "if you are crazy enough
to want it, then it can be turned on in /etc/remote."
 1.8 29-Mar-2006  yamt pull the following change from OpenBSD
and bump date of the manpage.

date: 2003/09/20 18:15:32; author: millert; state: Exp; lines: +4 -2
Implement hardwareflow varable in tip(1) like Solaris and hf in /etc/remote.
Based on PR 3411 from Matthew Gream
Also document "tandem" variable (XON/XOFF) in tip man page.
 1.7 23-Apr-2004  christos constify and warns = 3
 1.6 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.5 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.4 17-May-1997  pk NULL => 0 (Arne Juul; PR#3629)
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.13 14-Dec-2006  christos pass lint; from Anon Ymous
 1.12 14-Dec-2006  christos kill the (void)&foo; from Anon Ymous
 1.11 03-Apr-2006  perry Remove vestiges of the ACULOG support. It depended on the suid support
(which is now gone) and it is woefully obsolete -- if something
analogous is ever needed in the future, syslog is the way to do it.
 1.10 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.9 23-Apr-2004  christos constify and warns = 3
 1.8 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.7 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.6 11-Feb-1997  mrg give buffers lengths; use strdup.
 1.5 29-Dec-1996  cgd fix up -ansi -pedantic warnings produced because of static function
declarations nested in other functions. The solution: declare the
static functions at the top level.
 1.4 29-Oct-1995  pk Convert to termios (from Scott Reynolds; PR#1621).
8-bit patches (from Matthieu Herrb; PR#1384).
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.12 14-Dec-2006  christos pass lint; from Anon Ymous
 1.11 03-Apr-2006  perry Remove vestiges of the ACULOG support. It depended on the suid support
(which is now gone) and it is woefully obsolete -- if something
analogous is ever needed in the future, syslog is the way to do it.
 1.10 03-Apr-2006  perry Remove support for uucp style locking.

This means we can get rid of the suid/sgid parts of the code (which
have been removed). The program is now installed with normal permissions.

To prevent accidents, we now flock the tty line, attempting to get an
exclusive lock.

Reviewed by: tls
 1.9 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.8 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.7 12-Jul-1998  mrg KNF. ensure buffers are not overrun.
 1.6 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.5 11-Feb-1997  mrg give buffers lengths; use strdup.
 1.4 29-Oct-1995  pk Convert to termios (from Scott Reynolds; PR#1621).
8-bit patches (from Matthieu Herrb; PR#1384).
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.17 14-Dec-2006  christos pass lint; from Anon Ymous
 1.16 14-Dec-2006  christos kill the (void)&foo; from Anon Ymous
 1.15 03-Apr-2006  perry Remove vestiges of the ACULOG support. It depended on the suid support
(which is now gone) and it is woefully obsolete -- if something
analogous is ever needed in the future, syslog is the way to do it.
 1.14 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.13 23-Apr-2004  christos constify and warns = 3
 1.12 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.11 19-Dec-1998  christos sigvec->sigaction
sigblock->sigprocmask
sigpause->sigsuspend
XXX: code could be shared here.
 1.10 12-Jul-1998  mrg KNF. ensure buffers are not overrun.
 1.9 30-Mar-1998  mrg use static int instead of static
 1.8 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.7 11-Feb-1997  mrg give buffers lengths; use strdup.
 1.6 29-Dec-1996  cgd fix up -ansi -pedantic warnings produced because of static function
declarations nested in other functions. The solution: declare the
static functions at the top level.
 1.5 29-Oct-1995  pk Convert to termios (from Scott Reynolds; PR#1621).
8-bit patches (from Matthieu Herrb; PR#1384).
 1.4 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.3 01-Aug-1993  mycroft Add RCS identifiers.
 1.2 11-May-1993  cgd fix from Bakul Shah <bvs@BitBlocks.com> to make tip not dump core
when courier acu routines are used with a non-USR Courier modem.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.10 14-Dec-2006  christos pass lint; from Anon Ymous
 1.9 14-Dec-2006  christos kill the (void)&foo; from Anon Ymous
 1.8 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.7 23-Apr-2004  christos constify and warns = 3
 1.6 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.5 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.4 29-Oct-1995  pk Convert to termios (from Scott Reynolds; PR#1621).
8-bit patches (from Matthieu Herrb; PR#1384).
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.10 14-Dec-2006  christos pass lint; from Anon Ymous
 1.9 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.8 11-Mar-2004  uebayasi Use O_WRONLY / O_RDWR instead of bare integers.
 1.7 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.6 12-Jul-1998  mrg KNF. ensure buffers are not overrun.
 1.5 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.4 29-Oct-1995  pk Convert to termios (from Scott Reynolds; PR#1621).
8-bit patches (from Matthieu Herrb; PR#1384).
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.17 06-Sep-2011  joerg Use __dead. Make a bunch of local functions static.
 1.16 18-Jan-2009  lukem fix -Wsign-compare issues
 1.15 14-Dec-2006  christos pass lint; from Anon Ymous
 1.14 22-Oct-2006  christos sprinkle volatile.
 1.13 03-Apr-2006  christos Pass a little lint.
 1.12 03-Apr-2006  perry Remove vestiges of the ACULOG support. It depended on the suid support
(which is now gone) and it is woefully obsolete -- if something
analogous is ever needed in the future, syslog is the way to do it.
 1.11 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.10 23-Apr-2004  christos constify and warns = 3
 1.9 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.8 12-Jul-1998  mrg KNF. ensure buffers are not overrun.
 1.7 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.6 11-Feb-1997  mrg give buffers lengths; use strdup.
 1.5 01-Nov-1996  cgd translate '=' in phone number strings into ',' (to generate delays),
as is done for couriers and t3000s. Ahh, the wonders of being in
a hotel room with source.
 1.4 29-Oct-1995  pk Convert to termios (from Scott Reynolds; PR#1621).
8-bit patches (from Matthieu Herrb; PR#1384).
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.15 14-Dec-2006  christos pass lint; from Anon Ymous
 1.14 14-Dec-2006  christos kill the (void)&foo; from Anon Ymous
 1.13 03-Apr-2006  perry Remove vestiges of the ACULOG support. It depended on the suid support
(which is now gone) and it is woefully obsolete -- if something
analogous is ever needed in the future, syslog is the way to do it.
 1.12 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.11 23-Apr-2004  christos constify and warns = 3
 1.10 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.9 19-Dec-1998  christos sigvec->sigaction
sigblock->sigprocmask
sigpause->sigsuspend
XXX: code could be shared here.
 1.8 12-Jul-1998  mrg KNF. ensure buffers are not overrun.
 1.7 30-Mar-1998  mrg use static int instead of static
 1.6 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.5 11-Feb-1997  mrg give buffers lengths; use strdup.
 1.4 29-Dec-1996  cgd fix up -ansi -pedantic warnings produced because of static function
declarations nested in other functions. The solution: declare the
static functions at the top level.
 1.3 29-Oct-1995  pk Convert to termios (from Scott Reynolds; PR#1621).
8-bit patches (from Matthieu Herrb; PR#1384).
 1.2 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.1 08-Dec-1994  jtc branches: 1.1.1;
Initial revision
 1.1.1.1 08-Dec-1994  jtc imported from 4.4lite
 1.14 14-Dec-2006  christos pass lint; from Anon Ymous
 1.13 14-Dec-2006  christos kill the (void)&foo; from Anon Ymous
 1.12 03-Apr-2006  perry Remove vestiges of the ACULOG support. It depended on the suid support
(which is now gone) and it is woefully obsolete -- if something
analogous is ever needed in the future, syslog is the way to do it.
 1.11 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.10 23-Apr-2004  christos constify and warns = 3
 1.9 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.8 12-Jul-1998  mrg KNF. ensure buffers are not overrun.
 1.7 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.6 11-Feb-1997  mrg give buffers lengths; use strdup.
 1.5 29-Dec-1996  cgd fix up -ansi -pedantic warnings produced because of static function
declarations nested in other functions. The solution: declare the
static functions at the top level.
 1.4 29-Oct-1995  pk Convert to termios (from Scott Reynolds; PR#1621).
8-bit patches (from Matthieu Herrb; PR#1384).
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.13 30-Jun-2016  dholland PR 51192 David Binderman: fix wrong logic (probably)

XXX: this file should probably just be deleted
 1.12 14-Dec-2006  christos pass lint; from Anon Ymous
 1.11 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.10 23-Apr-2004  christos constify and warns = 3
 1.9 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.8 19-Dec-1998  christos char -> unsigned char
 1.7 12-Jul-1998  mrg KNF. ensure buffers are not overrun.
 1.6 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.5 29-Dec-1996  cgd fix up -ansi -pedantic warnings produced because of static function
declarations nested in other functions. The solution: declare the
static functions at the top level.
 1.4 29-Oct-1995  pk Convert to termios (from Scott Reynolds; PR#1621).
8-bit patches (from Matthieu Herrb; PR#1384).
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.17 22-Jul-2020  msaitoh s/reseting/resetting/
 1.16 14-Dec-2006  christos pass lint; from Anon Ymous
 1.15 14-Dec-2006  christos kill the (void)&foo; from Anon Ymous
 1.14 03-Apr-2006  perry Remove vestiges of the ACULOG support. It depended on the suid support
(which is now gone) and it is woefully obsolete -- if something
analogous is ever needed in the future, syslog is the way to do it.
 1.13 03-Apr-2006  perry ANSIfy decls, de-__P, clean trailing whitespace
 1.12 04-Nov-2004  dsl Add (unsigned char) cast to ctype functions
islower() can be true for 0x80..0xff
 1.11 23-Apr-2004  christos constify and warns = 3
 1.10 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22365, verified by myself.
 1.9 19-Dec-1998  christos char -> unsigned char
 1.8 12-Jul-1998  mrg KNF. ensure buffers are not overrun.
 1.7 22-Nov-1997  lukem WARNSify, KNFify, using ANSI string functions, cleanup .Nm usage
 1.6 11-Feb-1997  mrg give buffers lengths; use strdup.
 1.5 29-Dec-1996  cgd fix up -ansi -pedantic warnings produced because of static function
declarations nested in other functions. The solution: declare the
static functions at the top level.
 1.4 29-Oct-1995  pk Convert to termios (from Scott Reynolds; PR#1621).
8-bit patches (from Matthieu Herrb; PR#1384).
 1.3 08-Dec-1994  jtc Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
 1.2 01-Aug-1993  mycroft Add RCS identifiers.
 1.1 21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2 08-Dec-1994  jtc imported from 4.4lite
 1.1.1.1 21-Mar-1993  cgd initial import of 386bsd-0.1 sources

RSS XML Feed