History log of /freebsd-current/usr.bin/ctags/ctags.c
Revision Date Author Comments
# 87b0195a 06-Feb-2024 Collin Funk <collin.funk1@gmail.com>

ctags: Use C99 bool instead of defining our own

Use stdbool.h definitions instead of defining non-standard ones.

Signed-off-by: Collin Funk <collin.funk1@gmail.com>

Reviewed by: markj
MFC after: 2 weeks
Pull Request: https://github.com/freebsd/freebsd-src/pull/1107


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


# 498a0a9c 07-Jul-2023 Alfonso Gregory <gfunni234@gmail.com>

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


# 430d064b 25-May-2023 Dag-Erling Smørgrav <des@FreeBSD.org>

ctags: Support writing to stdout instead of a file.

* Understand "-" to mean stdout as per convention.
* Check that the output is a regular file and ignore -u if not, otherwise we might try to rm /dev/stdout.
* As a bonus, if -u was specified but the output file does not exist, proceed as if -u had not been specified instead of erroring out.

MFC after: 1 week
Sponsored by: Klara, Inc.
Reviewed by: cracauer, debdrup
Differential Revision: https://reviews.freebsd.org/D40237


# 50632117 23-May-2023 Dag-Erling Smørgrav <des@FreeBSD.org>

ctags: Error out if writing to stdout failed.

MFC after: 1 week
Sponsored by: Klara, Inc.
Reviewed by: cracauer, allanjude
Differential Revision: https://reviews.freebsd.org/D40200


# 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


# da52b4ca 11-Dec-2010 Joel Dahl <joel@FreeBSD.org>

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


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


# e42dd26a 05-Jan-2010 David Malone <dwmalone@FreeBSD.org>

Change a char that is used as an index into an array into an unisgned char.
Add a missing new style function definition.


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

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


# cd1de708 18-Jul-2006 Stefan Farfeleder <stefanf@FreeBSD.org>

Fix type mismatch between char * and unsigned char *. C guarantees that
the values of the characters here are positive, so it's safe to index arrays
with them.


# e0754837 07-May-2004 Crist J. Clark <cjc@FreeBSD.org>

It was pointed out[0] that ctags(1) uses some potentially dangerous
system(3) calls where user-supplied data is used with no sanity
checking. Since ctags(1) is not setuid and is not likely to be used
in a privileged situation, this is not a big deal. However, the
fix is relatively easy and less ugly than the current code, let's be
safe. (I'm sure there are about 2^134 other system(3) calls like this
out there.)

[0] On freebsd-security by Roman Bogorodskiy <bogorodskiy@inbox.ru>
with subject "ctags(1) command execution vulnerability."

MFC after: 3 days


# c10b37bf 28-Jul-2002 David Malone <dwmalone@FreeBSD.org>

ANSIify function definitions to avoid a warning.


# df111dde 30-May-2002 Tim J. Robbins <tjr@FreeBSD.org>

Sort entries by locale collating order when -x is specified.


# a5d52123 30-May-2002 Tim J. Robbins <tjr@FreeBSD.org>

Create tags for typedefs, structs, unions and enums by default (imply the
-t option). Make a new option, -T, to revert to the old behaviour.


# e58bac2e 30-May-2002 Tim J. Robbins <tjr@FreeBSD.org>

Avoid buffer overrun when identifies or filenames are extremely long.

OpenBSD revisions: C.c 1.4-1.5, ctags.c 1.5, fortran.c 1.3, lisp.c 1.3,
tree.c 1.2

Obtained from: OpenBSD


# 880ff113 26-May-2002 Tim J. Robbins <tjr@FreeBSD.org>

Exit non-zero if the tags file cannot be opened.


# f1bb2cd2 21-Mar-2002 Warner Losh <imp@FreeBSD.org>

remove __P


# 93b3633b 12-Dec-2001 Philippe Charnier <charnier@FreeBSD.org>

Remove unused #includes. lex -> Lex, yacc -> Yacc, ... Some .Nm to .Em
conversions. Sort #includes. Spelling. use errx() instead of err() when
explicit message is given.


# 9f5b04e9 10-Dec-2001 David Malone <dwmalone@FreeBSD.org>

Style improvements recommended by Bruce as a follow up to some
of the recent WARNS commits. The idea is:

1) FreeBSD id tags should follow vendor tags.
2) Vendor tags should not be compiled (though copyrights probably should).
3) There should be no blank line between including cdefs and __FBSDIF.


# f86b9f6d 02-Dec-2001 Mark Murray <markm@FreeBSD.org>

Use __FBSDID().


# acd1ad88 02-Dec-2001 Mark Murray <markm@FreeBSD.org>

WARNS=2 fixup.


# 1ac49cd8 16-Aug-2001 Mike Heffner <mikeh@FreeBSD.org>

Add $FreeBSD$

MFC after: 2 weeks


# 465ebdc6 02-Jul-1999 Bill Fumerola <billf@FreeBSD.org>

Add braces to avoid ambigious else.


# fa146c53 06-Dec-1998 Archie Cobbs <archie@FreeBSD.org>

Tweaks to allow compiling -Wall (mostly adding "const" to char rcsid[]).


# d7d10053 28-Dec-1997 Alexander Langer <alex@FreeBSD.org>

-Wall cleanup.


# c44252b6 06-Jul-1997 Bruce Evans <bde@FreeBSD.org>

Finish importing Lite2's src/usr.bin, except for ex, diff, grep, mail,
pascal and vmstat.sparc. All changed files on the vendor branch should
already have been imported.


# 044addf8 30-Jun-1997 Philippe Charnier <charnier@FreeBSD.org>

Add usage string. Typo in man page.


# 1c8af878 28-Mar-1997 Warner Losh <imp@FreeBSD.org>

compare return value from getopt against -1 rather than EOF, per the final
posix standard on the topic.


# 9c197ec1 26-Jul-1996 Paul Traina <pst@FreeBSD.org>

Add newline, closes bin/1433


# 9b50d902 26-May-1994 Rodney W. Grimes <rgrimes@FreeBSD.org>

BSD 4.4 Lite Usr.bin Sources