Commit Graph

1240 Commits

Author SHA1 Message Date
Poul-Henning Kamp
40244c2859 unset TZ from the environment so the timestamp gets the system default,
which is what syslogd presumably uses too.  Notice that the "protocol"
is bogus in not defining the timezone. "protocol" because it hardly
deserves the name :-)

closes bin/1739

Reported by:	Stefan Zehl <sec@wg.camelot.de>
1996-10-21 19:51:34 +00:00
Joerg Wunsch
04eaedf23d Correct the SYNOPSIS section of the man page to add the -p option. 1996-10-21 18:04:42 +00:00
Poul-Henning Kamp
bf6570c4a5 Don't access stuff we have realloc()'ed using the old pointer.
This is a sample of a new class of malloc usage errors that the
Junk option to phkmalloc will expose.

Found by: phkmalloc.
1996-10-21 08:51:58 +00:00
Wolfram Schneider
efcc77ba70 Better case insensitve search support for pattern with meta chars.
In some rare cases this does not work proper before flag FNM_ICASE was
added to fnmatch(3).
1996-10-20 16:54:51 +00:00
Søren Schmidt
b0dac7029f Added brandelf to SUBDIR. 1996-10-19 09:08:41 +00:00
Joerg Wunsch
0d4abe6259 Slightly improve the C and C++ support. Allow for function return
types being on the same line as the function name, this finally closes
PR # bin/1785.  Also allow :: and ~ as part of the function name, for
C++.

Still, C++ operator overloading will not be recognized as a valid
function name.  Fixing this would require a major overhaul of the \p
recognition parser.
1996-10-18 17:23:33 +00:00
Joerg Wunsch
28445a638f Some cleanup:
. correct a typo in regexp.c,
. implement a new "nc" (non-comment) feature to describe exceptions from
  the comment detection; there were problems in Perl with the $# operator
  that could not be solved by any other means,
. prevent blocklevel from becoming negative (due to earlier misdetected
  sequences), this is probably a workaround for the problem described
  in PR # bin/1785,
. update the Perl description to use the "nc" feature,
. update the man page for the "nc" and the undocumented "ab"/"ae"
  features.
1996-10-18 14:13:18 +00:00
Jean-Marc Zucconi
d508ff27b1 The -q option does not require a list of elements: the command 'ar q foo.a'
is perfectly valid and eventually creates an empty archive.
This is consistent with OSF1 V3.x, SunOS 4.x, ULTRIX 4.x and probably others.
1996-10-17 22:13:36 +00:00
Andrey A. Chernov
9c6b5b5dba Add -D_SKEY_INTERNAL to pick up non-API functions 1996-10-17 15:30:21 +00:00
Andrey A. Chernov
5a6fd1f366 Add -D_SKEY_INTERNAL to pick up non-API skey functions 1996-10-17 15:25:12 +00:00
Andrey A. Chernov
0696bbfafd Fix diagnostic: skey->key, we have key command 1996-10-17 12:06:05 +00:00
Bruce Evans
db6a4b8826 Use a (signed) int32_t counter instead of an `unsigned int' counter
for the GPROF4 case.  This allows a simpler method to be used for
non-statistical profiling (it allows overhead adjustments to be
subtracted from one counter without harm if that counter goes
negative; otherwise the adjustment would have to be distributed).

32 bit counters were already too small for GPROF4 with a 200MHz
clock.  int64_t counters should be used.
1996-10-16 21:02:49 +00:00
Søren Schmidt
fcfc24ca7d Utility to "brand" ELF binaries.
Man page to come...
For now use: <brandelf -t Linux linuxbin> to brand, and just
<brandelf> to verify branding on a ELF file. FreeBSD native is
set with <brandelf -t FreeBSD freebsdbin>.
1996-10-16 18:16:22 +00:00
Andrey A. Chernov
7c4355120c Simplify and improve parser.
Clarify manpage.
1996-10-16 03:12:22 +00:00
Andrey A. Chernov
4c6441ffd0 Save half of LC_COLLATE space
ASCIIfy data files, use RFC1345 symbolic names instead of hex codes
Improve parser and manpage
1996-10-15 22:05:18 +00:00
Joerg Wunsch
d58bdc29c7 Wow!, i finally found a usable vgrind definition for Perl. 1996-10-15 18:58:45 +00:00
Wolfram Schneider
139764e8e9 8-Bit character support.
Old locate(1) programs still works with the new database format, print
some garbage for 8 bit characters, but don't core (maybe except char 30).

7-Bit Puritan should not notice any difference. Same speed,
Same database size if the database contain only ASCII characters.

Reviewed by: ache
1996-10-13 01:44:43 +00:00
Wolfram Schneider
374e137655 export variable TMPDIR (which maybe set, but not exported in /etc/locate.rc) 1996-10-12 20:29:25 +00:00
Jordan K. Hubbard
bc2c47df4b Close PR#1781 - time returns with EXIT_SUCCESS on some failures
Submitted-By: Tor Egge <Tor.Egge@idt.ntnu.no>
1996-10-12 18:41:26 +00:00
Steve Price
97162b3f35 Remove extraneous comment, fix second-level tabs (one
tab and four spaces), and return error message in *err
instead of calling Parse_Error.

Suggested by: Bruce Evans <bde@zeta.org.au>
1996-10-12 02:15:30 +00:00
Steve Price
50dc64b15f Removed extra $Id$ string. 1996-10-11 04:15:57 +00:00
Steve Price
39dd3fffbf Reinstate '!=' fix by Bruce Evans. The original commit message from
parse.c(1.9) was:

revision 1.9
date: 1996/09/12 03:03:25;  author: bde;  state: Exp;  lines: +7 -6
Fixed handling of `!=' assignment.  Don't warn if the shell's output is
null, but warn if there was an error reading it.

Suggested by: Bruce Evans <bde@zeta.org.au>
1996-10-11 03:55:29 +00:00
Garrett Wollman
924a8fa376 Remove reference to oobsolete RTF_MASK flag (soon to be removed). 1996-10-09 18:19:07 +00:00
Wolfram Schneider
b72acdbdc5 Fix searching for shell quoting characters. I guess it was
broken since locate exists.

This works now

$ locate '*\['
$ locate '*i386-\**'
$ locate '*[C\[]'
1996-10-09 00:33:34 +00:00
Steve Price
5d55a64610 O' to be bitten by CVS. Cleanup after import
of Christos' version of make(1) and add Id's.

Set straight by: Bruce Evans and Peter Wemm :)
1996-10-08 04:07:59 +00:00
Joerg Wunsch
40a8a5cf5c Export $TERM only if it has been set in our environment.
Detected by: Amancio Hasty
1996-10-07 10:00:58 +00:00
Steve Price
85aa37cd56 This commit was generated by cvs2svn to compensate for changes in r18764,
which included commits to RCS files with non-trunk default branches.
1996-10-06 16:45:32 +00:00
Steve Price
ea09f5e44d Import Christos Zoulas' version of NetBSD's make onto the
vendor branch for reference.

Obtained from: Christos Zoulas <christos@netbsd.org>
1996-10-06 16:45:32 +00:00
Steve Price
66b6f9d1e4 Clarify the rule used to determine the object
directory location.
1996-10-06 16:19:08 +00:00
Peter Wemm
6c7089bce5 Import the 4.4BSD-Lite2 version of make onto the vendor branch
"for reference".  This doesn't change anything since all files
have been touched.
1996-10-06 15:57:15 +00:00
Peter Wemm
6b8f99f0db This commit was generated by cvs2svn to compensate for changes in r18756,
which included commits to RCS files with non-trunk default branches.
1996-10-06 15:57:15 +00:00
Steve Price
8b69153a4d Correct problem with traversing into PSD.doc directory,
these files are actually installed/built as part of
src/share/doc/psd/12.make.  Oops. :)

Pointed out by:	Peter Wemm and Bruce Evans
1996-10-06 13:02:43 +00:00
Jordan K. Hubbard
09502a0eb9 Correct merge bogon: You want to descend into PSD.doc for both `all' and
`install' cases or there's never anything made to install, and you blow
up in the install. :-)
1996-10-06 12:43:14 +00:00
Steve Price
e6068a345f Remove annoying -Wall warning. 1996-10-06 02:40:39 +00:00
cvs2svn
fd28c66eb8 This commit was manufactured by cvs2svn to create branch 'CHRISTOS'. 1996-10-06 02:35:39 +00:00
Steve Price
c0d06fe463 Merge in NetBSD's changes to make(1). Changes include:
- Add the .PHONY, .PARALLEL, and .WAIT directives
	- Added the -B and -m commandline flags
	- misc. man page cleanups
	- numerous job-related enhancements
	- removed unused header file (bit.h)
	- add util.c for functions not found in other envs.
	- and a few coordinated whitespace changes

Special thanks to Christos Zoulas <christos@netbsd.org>
for help in the merge.  A 'diff -ur' between Net and
FreeBSD now only contains sccsid-related diffs. :)

Obtained from: NetBSD, christos@netbsd.org, and me
1996-10-06 02:35:38 +00:00
Jordan K. Hubbard
d34dd13378 Honor the MAIL environment variable.
Submitted-By: Dan Cross <cross@math.psu.edu>
1996-10-06 01:55:32 +00:00
Jordan K. Hubbard
338fc8eb62 Honor the MAIL environment variable, if set.
Submitted-by: Dan Cross <cross@math.psu.edu>
1996-10-06 01:54:22 +00:00
Jean-Marc Zucconi
b84aaff96e The -h flag implies ftp = 1. 1996-10-06 00:44:24 +00:00
Peter Wemm
3598e52ce6 With -delete, don't complain about non-empty directories. Otherwise
"cd /tmp; find . -mtime +7 -delete" is excessively noisy.
1996-10-05 23:47:07 +00:00
John Fieber
ad8b2071ac Some new options for the FreeBSD web pages. These are for the moment
not officially documented and are subject to change.

 -hdr and -ftr
	Specify files to insert at the top and bottom of every
	page.  This is similar in result to the existing -ssi
	option but everything happens at build time.  If the
	string @@UPDATED@@ appears in either file it will be
	replaced with "Updated" followed by the current date.

-white
	Make the pages black text on white background.
1996-10-05 23:38:55 +00:00
Wolfram Schneider
e83201b43a delete doubled words, e.g.: "the the" -> "the" 1996-10-05 22:27:30 +00:00
Peter Wemm
242ab807c6 For the -delete option, emulate the behavior of "rm -f" when dealing with
user-immutable files.

Requested by: ache
1996-10-05 18:21:05 +00:00
Andrey A. Chernov
4f2d3b038d Fix Moscow timezone rule 1996-10-05 09:03:37 +00:00
Peter Wemm
7520d11894 Fix the previous commit. The second of the 8-character columns was
a duplicate of the first column of 8...
1996-10-04 23:29:38 +00:00
Peter Wemm
abacbbbf01 Implement a -delete option to find. The code is extremely paranoid and
goes to a fair degree of trouble to enable something like this to
be safe:  cd /tmp && find . -mtime +7 -delete

It removes both files and directories.  It does not attempt to remove
immutable files (an earlier version I showed to a few people did a chflags
and tried to blow away even immutable files.  Too risky..)

It is thought to be safe because it forces the fts(3) driven descent to
only do "minimal risk" stuff.  specifically, -follow is disabled, it does
checking to see that it chdir'ed to the directory it thought it was
going to, it will *not* pass a pathname with a '/' character in it to
unlink(), so it should be totally immune to symlink tree races.  If it runs
into something "fishy", it bails out rather than blunder ahead.. It's better
to do that if somebody is trying to compromise security rather than risk
giving them an opportunity.  Since the unlink()/rmdir() is being called
from within the current working directory during the tree descent, there
are no fork/exec overheads or races.

As a side effect of this paranoia, you cannot do a
"find /somewhere/dir -delete", as the last argument to rmdir() is
"/somewhere/dir", and the checking won't allow it.  Besides, one would use
rm -rf for that case anyway. :-)

Reviewed by: pst (some time ago, but I've removed the immutable file
deletion code that he complained about since he last saw it)
1996-10-04 12:54:07 +00:00
John Fieber
d0d723ef05 When starting HTML generation, remove any pre-existing link file. 1996-10-01 16:23:39 +00:00
Peter Wemm
d72f654c65 When used as a shell builtin, this program decoded a subset of arguments
known to printf(3) and then used printf() to format it... The only
problem what the #define printf out1fmt.  The code was behaving differently
when run as a shell builtin since out1fmt() isn't printf(3).

Simple hack.  Print to a buffer and fputs (also #defined for sh) the
result.  This should fix the printf builtin problem in PR#1673, rather
than leaving the call commented out.  (printf.o was being statically linked
in anyway, we might as well use it)
1996-10-01 04:56:59 +00:00
Warner Losh
a3e5ddb707 Sync usage line to man page, per style(9).
Pointed out by: Bruce Evans <bde@zeta.org.au>
1996-10-01 03:59:57 +00:00
Peter Wemm
9731d13765 Incorporate John Polstra's sods.c display of the details about the
dynamic linking information in the executable.  It's quite extensive.
It's connected to ldd's (new) -v option.
1996-10-01 02:16:16 +00:00