History log of /freebsd-current/usr.bin/tip/tip/tip.c
Revision Date Author Comments
# 0b8224d1 24-Nov-2023 Warner Losh <imp@FreeBSD.org>

Remove copyright strings ifdef'd out

We've ifdef'd out the copyright strings for some time now. Go ahead and
remove the ifdefs. Plus whatever other detritis was left over from other
recent removals. These copyright strings are present in the comments and
are largely from CSRG's attempt at adding their copyright to every
binary file (which modern interpretations of the license doesn't
require).

Sponsored by: Netflix


# bdcbfde3 23-Nov-2023 Warner Losh <imp@FreeBSD.org>

usr.bin: Remove ancient SCCS tags.

Remove ancient SCCS tags from the tree, automated scripting, with two
minor fixup to keep things compiling. All the common forms in the tree
were removed with a perl script.

Sponsored by: Netflix


# 1d386b48 16-Aug-2023 Warner Losh <imp@FreeBSD.org>

Remove $FreeBSD$: one-line .c pattern

Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/


# a86ddfe8 06-Apr-2020 Kyle Evans <kevans@FreeBSD.org>

mail/gprof/tip: tap with the ugly stick

The ugly stick here is this bit in the respective headers:

#ifndef EXTERN
#define EXTERN extern
#endif

with a follow-up #define EXTERN in a single .c file to push all of their
definitions into one spot. A pass should be made over these three later to
push these definitions into the correct files instead, but this will suffice
for now and at a more leisurely pace.

MFC after: 3 days


# f5c072fb 29-Jan-2020 Dimitry Andric <dim@FreeBSD.org>

Fix the following -Werror warning from clang 10.0.0 in tip:

usr.bin/tip/tip/tip.c:428:4: error: misleading indentation; statement is not part of the previous 'if' [-Werror,-Wmisleading-indentation]
if (gch == EOF)
^
usr.bin/tip/tip/tip.c:426:5: note: previous statement is here
} else if (!cumode && gch == character(value(FORCE)))
^

The intent was to have the EOF check grouped with the getchar() call
just above it. This was accidentally introduced in r354624.

MFC after: 3 days


# 55211796 11-Nov-2019 Eric van Gyzen <vangyzen@FreeBSD.org>

tip/cu: check for EOF on input on the local side

If cu reads an EOF on the input side, it goes into a tight loop
sending a garbage byte to the remote. With this change, it exits
gracefully, along with its child.

MFC after: 2 weeks
Sponsored by: Dell EMC Isilon


# 8a16b7a1 20-Nov-2017 Pedro F. Giffuni <pfg@FreeBSD.org>

General further adoption of SPDX licensing ID tags.

Mainly focus on files that use BSD 3-Clause license.

The Software Package Data Exchange (SPDX) group provides a specification
to make it easier for automated tools to detect and summarize well known
opensource licenses. We are gradually adopting the specification, noting
that the tags are considered only advisory and do not, in any way,
superceed or replace the license texts.

Special thanks to Wind River for providing access to "The Duke of
Highlander" tool: an older (2014) run over FreeBSD tree was useful as a
starting point.


# 91505ba4 28-Jan-2012 Poul-Henning Kamp <phk@FreeBSD.org>

Make tip exit if the device disappears, for instance when unplugging
or resetting USB serial devices.

Somebody[tm] should rewrite tip(1) to use two thread instead of two
processes or maybe even use that new-fangled "select(2)" or positively
futuristic "poll(2)" system call.


# a7d5f7eb 19-Oct-2010 Jamie Gritton <jamie@FreeBSD.org>

A new jail(8) with a configuration file, to replace the work currently done
by /etc/rc.d/jail.


# fe0506d7 09-Mar-2010 Marcel Moolenaar <marcel@FreeBSD.org>

Create the altix project branch. The altix project will add support
for the SGI Altix 350 to FreeBSD/ia64. The hardware used for porting
is a two-module system, consisting of a base compute module and a
CPU expansion module. SGI's NUMAFlex architecture can be an excellent
platform to test CPU affinity and NUMA-aware features in FreeBSD.


# d7f03759 19-Oct-2008 Ulf Lilleengen <lulf@FreeBSD.org>

- Import the HEAD csup code which is the basis for the cvsmode work.


# a0ad4c4d 02-May-2008 Bruce M Simpson <bms@FreeBSD.org>

Relinquish exclusive TTY access when tip(1) or cu(1) exit.
Previously they would have left TIOCEXCL enabled, requiring
either a reboot or use of tip/cu as the root user.

Observed when running QEMU with character devices redirected to pty instances.

MFC after: 2 weeks


# 07bb01e3 31-Aug-2006 Ruslan Ermilov <ru@FreeBSD.org>

Fix compilation warnings (up to level 3).


# fa92e883 31-Aug-2006 Ruslan Ermilov <ru@FreeBSD.org>

Resolve merge conflicts.


# d391708c 31-Aug-2006 Ruslan Ermilov <ru@FreeBSD.org>

Import OpenBSD's tip(1) as of today


# 229c0017 06-Apr-2003 Warner Losh <imp@FreeBSD.org>

make prototpyes match functions, and declare things static as needed


# 0f3bdf5d 20-Dec-2001 Mark Murray <markm@FreeBSD.org>

Import of OpenBSD's tip (which was the tip code of a month ago, modulo
OpenBSD commits).


# 62f9fae6 24-May-2001 Poul-Henning Kamp <phk@FreeBSD.org>

If the user exists abruptly, tip's "tipout" child can hang around
forever. Since the lock file doesn't get cleaned up, this prevents
other users from accessing the target device.

(phk adds: Man, this has been bugging me for YEARS!)

PR: 12528
Submitted by: Craig Leres leres@ee.lbl.gov
MFC after: 1 week


# 0e7f0658 14-Apr-2000 Warner Losh <imp@FreeBSD.org>

#include <errno.h> where needed. Kill extern int errno;.

Minor warnings in tip corrected.


# e46b89dc 14-Sep-1999 Peter Wemm <peter@FreeBSD.org>

Fix warning: return type of `main' is not `int'


# c3aac50f 27-Aug-1999 Peter Wemm <peter@FreeBSD.org>

$Id$ -> $FreeBSD$


# 64edd876 04-Apr-1999 Dmitrij Tejblum <dt@FreeBSD.org>

Rename a function to avoid conflict with the new syscall 'pwrite'.


# 5dbf068b 09-Jun-1998 Warner Losh <imp@FreeBSD.org>

sizeof(foo - 1) isn't the same as sizeof(foo) - 1.

Pointed out by: Theo De Raadt.


# f34c49eb 08-Jun-1998 Warner Losh <imp@FreeBSD.org>

o Use snprintf rather than sprintf.
o Revert gid to caller before a shell so we can run setgid.
o minor style nits to make bruce happy :-)
o use strncpy correctly.


# d030d2d2 18-Sep-1997 Poul-Henning Kamp <phk@FreeBSD.org>

Many places in the code NULL is used in integer context, where
plain 0 should be used. This happens to work because we #define
NULL to 0, but is stylistically wrong and can cause problems
for people trying to port bits of code to other environments.

PR: 2752
Submitted by: Arne Henrik Juul <arnej@imf.unit.no>


# a8b28da0 26-Aug-1997 Eivind Eklund <eivind@FreeBSD.org>

Removed a buffer overflow in args().

While I'm here, fix a bug with 'register' in conjunction with setjmp(),
staticize and do some -Wall cleaning.


# daca8650 24-Aug-1997 Warner Losh <imp@FreeBSD.org>

Change from using sys/param.h and MAXPATHLEN to using limits.h and PATH_MAX
to avoid the NOFILE problem. Back out NOFILE kludge. Fix unexploitable
buffer overflow in tipout.c.
Reviewed by: millert@openbsd.org (tipout.c)
Submitted by: millert@openbsd.org (rest of idea)


# 29ae2e93 22-Aug-1997 Warner Losh <imp@FreeBSD.org>

Fix buffer overflow. prompt didn't get a size for its buffer,
so it could overflow it. Also made some filenames MAXPATHLEN long rather
than 80 long.


# 804d2dab 18-Aug-1997 Philippe Charnier <charnier@FreeBSD.org>

Add prototypes, usage(). Use err(3).


# dc22f7a9 26-Nov-1995 Poul-Henning Kamp <phk@FreeBSD.org>

Make tip recognize EOF in more cases.


# 18cc36fb 31-Mar-1995 Jordan K. Hubbard <jkh@FreeBSD.org>

Tom Gray's new tip changes to support a modem capabilities database and
fixes to many assorted bugs and misfeatures.
Submitted by: Tom Gray - DCA <dcasba@rain.org>