Commit Graph

143 Commits

Author SHA1 Message Date
Warner Losh
b2c76c41be Remove $FreeBSD$: one-line nroff pattern
Remove /^\.\\"\s*\$FreeBSD\$$\n/
2023-08-16 11:55:15 -06:00
Warner Losh
fa9896e082 Remove $FreeBSD$: two-line nroff pattern
Remove /^\.\\"\n\.\\"\s*\$FreeBSD\$$\n/
2023-08-16 11:55:10 -06:00
Warner Losh
d0b2dbfa0e Remove $FreeBSD$: one-line sh pattern
Remove /^\s*#[#!]?\s*\$FreeBSD\$.*$\n/
2023-08-16 11:55:03 -06:00
Warner Losh
1d386b48a5 Remove $FreeBSD$: one-line .c pattern
Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
2023-08-16 11:54:42 -06:00
Warner Losh
42b388439b Remove $FreeBSD$: one-line .h pattern
Remove /^\s*\*+\s*\$FreeBSD\$.*$\n/
2023-08-16 11:54:23 -06:00
Warner Losh
b3e7694832 Remove $FreeBSD$: two-line .h pattern
Remove /^\s*\*\n \*\s+\$FreeBSD\$$\n/
2023-08-16 11:54:16 -06:00
Alfonso Gregory
a1b6427a97 Mark usage function as __dead2 in programs where it does not return
In most cases, usage does not return, so mark them as __dead2. For the
cases where they do return, they have not been marked __dead2.

Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/735
2023-07-07 10:45:18 -06:00
Warner Losh
4d846d260e spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSD
The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch
up to that fact and revert to their recommended match of BSD-2-Clause.

Discussed with:		pfg
MFC After:		3 days
Sponsored by:		Netflix
2023-05-12 10:44:03 -06:00
Simon J. Gerraty
d9a4274795 Update/fix Makefile.depend for userland 2023-04-18 17:14:23 -07:00
Pedro F. Giffuni
1de7b4b805 various: general adoption of SPDX licensing ID tags.
Mainly focus on files that use BSD 2-Clause license, however the tool I
was using misidentified many licenses so this was mostly a manual - error
prone - task.

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.

No functional change intended.
2017-11-27 15:37:16 +00:00
Pedro F. Giffuni
8a16b7a18f 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.
2017-11-20 19:49:47 +00:00
Bryan Drewery
ea825d0274 DIRDEPS_BUILD: Update dependencies.
Sponsored by:	Dell EMC Isilon
2017-10-31 00:07:04 +00:00
Stephen J. Kiernan
ee27b3cd98 The variable nargv is allocated but never freed, so free it when the it
is no longer used.

Submitted by:	Thomas Rix <trix@juniper.net>
Reviewed by:	ed
Approved by:	sjg (mentor)
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D9652
2017-06-13 15:50:16 +00:00
Warner Losh
fbbd9655e5 Renumber copyright clause 4
Renumber cluase 4 to 3, per what everybody else did when BSD granted
them permission to remove clause 3. My insistance on keeping the same
numbering for legal reasons is too pedantic, so give up on that point.

Submitted by:	Jan Schaumann <jschauma@stevens.edu>
Pull Request:	https://github.com/freebsd/freebsd/pull/96
2017-02-28 23:42:47 +00:00
Marcelo Araujo
7a4b1114b1 Use NULL instead of 0 for pointers.
strchr(3) will return NULL if the character does not appear in the
string.

MFC after:	2 weeks.
2016-04-18 14:44:01 +00:00
Kurt Lidl
6e786098f2 Do not truncate office phones in finger's summary listing
When finger is invoked as as "finger username", it produces the
long listing by default, and phones numbers are pretty-printed
by the prphone() function. When invoked as just "finger", the
same pretty-printing happens, but is truncated at 9 characters.
Given the summary listing is already greater than 80 columns,
making it even wider is of no harm.

Approved by:	rpaulo (mentor)
Differential Revision:	https://reviews.freebsd.org/D5638
2016-03-14 22:20:22 +00:00
Baptiste Daroussin
410df9fd8d Fix printing multibyte printing when performing a networked finger(1) request
MFC after:	1 week
2016-01-18 20:47:04 +00:00
Simon J. Gerraty
ccfb965433 Add META_MODE support.
Off by default, build behaves normally.
WITH_META_MODE we get auto objdir creation, the ability to
start build from anywhere in the tree.

Still need to add real targets under targets/ to build packages.

Differential Revision:       D2796
Reviewed by: brooks imp
2015-06-13 19:20:56 +00:00
Simon J. Gerraty
44d314f704 dirdeps.mk now sets DEP_RELDIR 2015-06-08 23:35:17 +00:00
Simon J. Gerraty
fae50821ae Updated dependencies 2014-05-16 14:09:51 +00:00
Simon J. Gerraty
76b28ad6ab Updated dependencies 2014-05-10 05:16:28 +00:00
Simon J. Gerraty
7cf3a1c6b2 Updated dependencies 2013-03-11 17:21:52 +00:00
Simon J. Gerraty
f5f7c05209 Updated dependencies 2013-02-16 01:23:54 +00:00
Simon J. Gerraty
23090366f7 Sync from head 2012-11-04 02:52:03 +00:00
Ed Schouten
bf70becee6 More -Wmissing-variable-declarations fixes.
In addition to adding `static' where possible:

- bin/date: Move `retval' into extern.h to make it visible to date.c.
- bin/ed: Move globally used variables into ed.h.
- sbin/camcontrol: Move `verbose' into camcontrol.h and fix shadow warnings.
- usr.bin/calendar: Remove unneeded variables.
- usr.bin/chat: Make `line' local instead of global.
- usr.bin/elfdump: Comment out unneeded function.
- usr.bin/rlogin: Use _Noreturn instead of __dead2.
- usr.bin/tset: Pull `Ospeed' into extern.h.
- usr.sbin/mfiutil: Put global variables in mfiutil.h.
- usr.sbin/pkg: Remove unused `os_corres'.
- usr.sbin/quotaon, usr.sbin/repquota: Remove unused `qfname'.
2012-10-19 14:49:42 +00:00
Eitan Adler
eae8be706e Bump date missed in r202756
PR:		docs/171624
Submitted by:	bdrewery
Approved by:	gabor
MFC after:	3 days
2012-09-14 17:50:42 +00:00
Marcel Moolenaar
7750ad47a9 Sync FreeBSD's bmake branch with Juniper's internal bmake branch.
Requested by: Simon Gerraty <sjg@juniper.net>
2012-08-22 19:25:57 +00:00
Ed Schouten
b3608ae18f Replace index() and rindex() calls with strchr() and strrchr().
The index() and rindex() functions were marked LEGACY in the 2001
revision of POSIX and were subsequently removed from the 2008 revision.
The strchr() and strrchr() functions are part of the C standard.

This makes the source code a lot more consistent, as most of these C
files also call into other str*() routines. In fact, about a dozen
already perform strchr() calls.
2012-01-03 18:51:58 +00:00
Ulrich Spörlein
487ac9ac21 Spelling fixes for usr.bin/ 2011-12-30 11:02:40 +00:00
Ed Schouten
c5d693c5d0 Build finger(1) with WARNS=6. 2011-10-14 07:24:23 +00:00
Xin LI
cde9717b67 Staticify cleanup() which is not referenced in other places.
MFC after:	2 weeks
2011-06-21 20:33:55 +00:00
Simon L. B. Nielsen
6e46c1cc7d Check return code of setuid() and setgid() in finger.
While they will not fail in normal circumstances, better safe than
sorry.

MFC after:	1 week
2011-04-23 14:19:26 +00:00
Joel Dahl
da52b4caaf Remove the advertising clause from UCB copyrighted files in usr.bin. This
is in accordance with the information provided at
ftp://ftp.cs.berkeley.edu/pub/4bsd/README.Impt.License.Change

Also add $FreeBSD$ to a few files to keep svn happy.

Discussed with:	imp, rwatson
2010-12-11 08:32:16 +00:00
Ed Schouten
0806dd9238 Remove stale references to utmp(5) and its corresponding filenames.
I removed utmp and its manpage, but not other manpages referring to it.
2010-01-21 17:25:12 +00:00
Ed Schouten
550dcc5960 Migrate finger(1) towards utmpx.
It was already ported to use libulog, which makes it simpler now. Be
sure to catch the error returned by setutxdb(). Otherwise it may perform
a lookup on the utx.active database.
2010-01-13 17:50:58 +00:00
Ed Schouten
b7946da96b Build usr.bin/ with WARNS=6 by default.
Also add some missing $FreeBSD$ to keep svn happy.
2010-01-02 10:27:05 +00:00
Ed Schouten
70ad88f354 Migrate finger(1) away from <utmp.h>.
Unfortunately it also uses lastlog, which means we must resort to local
extensions of the utmpx-interface. Because the user name and TTY name
are now nul-terminated, there is no need to copy around strings as
often.
2009-12-28 20:54:34 +00:00
Xin LI
13cf266e82 Plug a memory leak.
PR:		bin/141836
Submitted by:	Henning Petersen <henning.petersen at t-online.de>
MFC after:	2 weeks
2009-12-21 19:15:30 +00:00
Xin LI
821df508e8 Revert most part of 200420 as requested, as more review and polish is
needed.
2009-12-13 03:14:06 +00:00
Xin LI
6f2d322192 Remove unneeded header includes from usr.bin/ except contributed code.
Tested with:	make universe
2009-12-11 23:35:38 +00:00
Ruslan Ermilov
1e5f1c29ea Restore the ".Sh BUGS" line that was accidentally removed
in the previous commit.
2007-04-12 08:22:49 +00:00
Dag-Erling Smørgrav
ae16dc8817 Remove irrelevant comment about T/TCP in BUGS.
Spotted by:	ru@
2007-04-11 20:32:59 +00:00
Dag-Erling Smørgrav
b49339d790 Remove -T from getopt() spec and usage string.
Submitted by:	ru@
2007-04-11 20:32:09 +00:00
Dag-Erling Smørgrav
e705dbe22c Bump Dd. 2007-04-11 19:20:42 +00:00
Dag-Erling Smørgrav
f8871cc86d Remove T/TCP support, and the -T option which was needed to disable it.
MFC after:	3 weeks
2007-04-11 19:11:54 +00:00
Robert Watson
e0f5d997de Reduce number of spaces for full name by four, and reduce padding
after tty entry by one space in order to provide extra spaces for
the tty entry.  As a result, full pts names are now visible (up
to 999 pts's anyway):

Before:
Login            Name                 TTY  Idle  Login  Time   Office  Phone
robert           Robert Watson       *v0   3:55  Fri    02:54
robert           Robert Watson        p0     19  Sat    11:01
robert           Robert Watson        pts        Sat    14:55

After:

Login            Name             TTY      Idle  Login  Time   Office  Phone
robert           Robert Watson   *v0       5:08  Fri    02:54
robert           Robert Watson    p0          8  Sat    11:01
robert           Robert Watson    pts/5          Sat    14:55

MFC after:	1 week
2006-03-04 16:13:16 +00:00
Diomidis Spinellis
d2e4ea2a51 Setting .nofinger will not hide you from root. 2005-09-19 10:11:47 +00:00
Ruslan Ermilov
f682f10c76 Sync program's usage() with manpage's SYNOPSIS. 2005-05-21 09:55:10 +00:00
Ruslan Ermilov
6b806d21d1 Fixed the misplaced $FreeBSD$. 2005-02-09 18:07:17 +00:00
Ruslan Ermilov
6c7216df78 Sort sections. 2005-01-18 13:43:56 +00:00