History log of /freebsd-current/bin/ps/fmt.c
Revision Date Author Comments
# e043f372 24-Nov-2023 Warner Losh <imp@FreeBSD.org>

bin: Automated cleanup of cdefs and other formatting

Apply the following automated changes to try to eliminate
no-longer-needed sys/cdefs.h includes as well as now-empty
blank lines in a row.

Remove /^#if.*\n#endif.*\n#include\s+<sys/cdefs.h>.*\n/
Remove /\n+#include\s+<sys/cdefs.h>.*\n+#if.*\n#endif.*\n+/
Remove /\n+#if.*\n#endif.*\n+/
Remove /^#if.*\n#endif.*\n/
Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/types.h>/
Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/param.h>/
Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/capsicum.h>/

Sponsored by: Netflix


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

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/


# 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.


# fbbd9655 28-Feb-2017 Warner Losh <imp@FreeBSD.org>

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


# 9f0b6e5e 18-Jan-2013 John Baldwin <jhb@FreeBSD.org>

- Move 'showthreads' check out of fmt.c.
- Update shadow copy of fmt_argv() prototype in w.c and fix calls for
additional parameter.


# 1c67ef12 18-Jan-2013 John Baldwin <jhb@FreeBSD.org>

Include the thread name along with the command name when displaying the
command name of a thread from a multi-threaded process that doesn't have
an available argument list (such as kernel processes) and threads display
is enabled via -H.

Reviewed by: alfred, delphij, eric@vangyzen.net
MFC after: 1 week


# 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.


# 29d2bd43 21-Jun-2004 Garance A Drosehn <gad@FreeBSD.org>

Get rid of a cast to '(void) ' on the return of a call to strcpy.


# bdbc9a5c 21-Jun-2004 Garance A Drosehn <gad@FreeBSD.org>

Oops. Undo that last 'const' change. It expects similar changes to some
other files that I am not ready to commit yet...


# db6e0b8b 21-Jun-2004 Garance A Drosehn <gad@FreeBSD.org>

Add 'const' to a few places.

PR: bin/65803
Submitted by: Cyrille Lefevre


# e4b70e66 21-Jun-2004 Garance A Drosehn <gad@FreeBSD.org>

When displaying the "COMMAND" field for system-processes and/or kernel
threads, put the command name in square brackets instead of parenthesis.
This matches NetBSD, and also seems to be what linux does. The sentence
which is added to the man page is taken straight from NetBSD.

PR: bin/65803
Submitted by: Cyrille Lefevre
Obtained from: NetBSD


# 6195fb41 06-Apr-2004 Mark Murray <markm@FreeBSD.org>

Remove clause 3 from the UCB licenses.

OK'ed by: imp, core


# 6f0a94a9 03-May-2003 Mark Murray <markm@FreeBSD.org>

Fix long constant usage for i386.

Tested by: Joe Marcus Clarke <marcus@marcuscom.com>


# 40feca3a 03-May-2003 Mark Murray <markm@FreeBSD.org>

Fix a bazillion warnings. This makes almost the whole of src/bin/*
WARNS=6, std=c99 clean.

Tested on: i386, alpha


# eaed5652 05-Feb-2003 Philippe Charnier <charnier@FreeBSD.org>

Display elapsed time (-o etime) using [[dd-]hh:]mm:ss, which according to
Solaris man page is the POSIX way.

Reviewed by: jmallett


# 0ad736e6 05-Jul-2002 Mike Barcroft <mike@FreeBSD.org>

Don't depend on pollution in <limits.h> for the definition of
<stdint.h> macros.


# 2749b141 29-Jun-2002 David E. O'Brien <obrien@FreeBSD.org>

Consistently use FBSDID


# 6bb72963 06-Jun-2002 Juli Mallett <jmallett@FreeBSD.org>

Back out previous back out of previously correct code.

Double-plus-pointy-hat to: jmallett
Submitted by: bde


# 3d0d5dcc 06-Jun-2002 Juli Mallett <jmallett@FreeBSD.org>

Cast arg_max to size_t when comparing it (times 4, plus 1) against SIZE_MAX. I
was worried about truncation of arg_max by this cast, but if it gets truncated,
we know it'll obviously be greater than SIZE_MAX anyway.

Big pointy hat to: jmallett
Submitted by: keramida


# 05051e28 04-Jun-2002 Juli Mallett <jmallett@FreeBSD.org>

Returning NULL here if malloc(3) fails is silly, at this point in the codepath
we have't malloc(3)'d nearly as much as we probably will, so errx(3) away,
instead of waiting for something to fail yet again later on.


# 86f54b9f 04-Jun-2002 Juli Mallett <jmallett@FreeBSD.org>

Remove an XXX comment that seems to be a tiny bit no longer pertinent. This
function seems to do the right thing, and is not a "stub", and whoever "marc"
is, he's had plenty of time to do "the real one", so don't wait around for
him any longer.


# b69566d8 04-Jun-2002 Juli Mallett <jmallett@FreeBSD.org>

Use of zero here meant many things, NULL, '\0' (NUL), and 0. Sort it out.


# 634d96e1 04-May-2002 Juli Mallett <jmallett@FreeBSD.org>

Check for possible overflow from sysconf _SC_ARG_MAX and error out in a
correct manner. Revert my incorrect change to use err(3) for malloc(3)
failing. Use a size_t variable to store the size of the argument buffer
we allocate, and remove silly casts as the result of having this around.
Modify the math in some of the paranoid checks for buffer overflow to
account for the fact we now are dealing with the actual size of the
buffer. Remove the static qualifier for arg_max, and the bogus setting
of it to -1.

Include <limits.h> for the definitions we use to check for possible
overflows.

Submitted by: bde


# 3d674c94 01-May-2002 Juli Mallett <jmallett@FreeBSD.org>

Don't cast incorrectly to malloc(3), and don't use errx(3) if malloc(3)
returns NULL, as malloc(3) sets errno. Use err(3).


# 871e8d8c 03-Feb-2002 Mark Murray <markm@FreeBSD.org>

WARNS=4 fixes (incomplete, so set NO_WERROR), and lots of extra
cleanup courtesy of automatic checking (lint).


# 46251dde 01-Feb-2002 Warner Losh <imp@FreeBSD.org>

o __P has been reoved
o Old-style K&R declarations have been converted to new C89 style
o register has been removed
o prototype for main() has been removed (gcc3 makes it an error)
o int main(int argc, char *argv[]) is the preferred main definition.
o Attempt to not break style(9) conformance for declarations more than
they already are.


# 6b8a6a6e 19-Jan-2002 Mike Heffner <mikeh@FreeBSD.org>

Prevent overflowing the buffer that stores the command arguments.

PR: bin/19422
Not objected to by: -audit
MFC after: 3 weeks


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

$Id$ -> $FreeBSD$


# b98f433d 07-Dec-1998 Bruce Evans <bde@FreeBSD.org>

Fixed -Wall regression (broken in rev.1.12). Removed unused includes.


# c7bca093 17-Jun-1998 Joseph Koshy <jkoshy@FreeBSD.org>

Remove compile time dependency on ARG_MAX.

PR: 1791 (partial)
Reviewed by: Bruce Evans <bde@freebsd.org>, Tor Egge <tegge@freebsd.org>


# c9a8d1f4 15-May-1998 Philippe Charnier <charnier@FreeBSD.org>

Correct use of .Nm. Add rcsid.


# c4694019 01-Jul-1997 Bruce Evans <bde@FreeBSD.org>

Import Lite2's src/bin. All files in src/bin are off the vendor branch,
so this doesn't change the active versions.


# 02289df9 10-Mar-1997 Guido van Rooij <guido@FreeBSD.org>

Fix buffer overflow (probably unexploitable).


# b97fa2ef 22-Feb-1997 Peter Wemm <peter@FreeBSD.org>

Revert $FreeBSD$ to $Id$


# 1130b656 14-Jan-1997 Jordan K. Hubbard <jkh@FreeBSD.org>

Make the long-awaited change from $Id$ to $FreeBSD$

This will make a number of things easier in the future, as well as (finally!)
avoiding the Id-smashing problem which has plagued developers for so long.

Boy, I'm glad we're not using sup anymore. This update would have been
insane otherwise.


# 78b09ffe 13-Dec-1996 Steve Price <steve@FreeBSD.org>

-Wall cleaning.


# 5b28d454 23-Oct-1995 Andrey A. Chernov <ache@FreeBSD.org>

Remove unneded ctype.h


# 632f53dd 09-Mar-1995 David Greenman <dg@FreeBSD.org>

Fix previous fix that removes an unnecessary space; the output is now
just like it was in 1.1.5.


# fa49dc9c 10-Nov-1994 Andreas Schulz <ats@FreeBSD.org>

Fix an error to prevent some core dumps from ps.
You can get ps easily to core dump, if you are running a "make depend"
on a kernel in one window and a "ps -auxww" in another. The ww will
try to give you the full argument list of the command that can
now be 64Kb large, but ps expected only 4Kb large arg arrays and
doesn't check for overflows.


# 89730b29 23-Sep-1994 David Greenman <dg@FreeBSD.org>

Added $Id$


# d9346a80 18-Aug-1994 David Greenman <dg@FreeBSD.org>

Got rid of extra space between args and (command).


# 4b88c807 26-May-1994 Rodney W. Grimes <rgrimes@FreeBSD.org>

BSD 4.4 Lite bin Sources