Commit Graph

6067 Commits

Author SHA1 Message Date
Juli Mallett
f67b533a2e In VarHead(), look into the correct (modified) string. 2002-10-29 12:11:56 +00:00
Ruslan Ermilov
36c4697a65 Mention that the left-hand side of the comparison
conditional must always be a variable expansion.

Obtained from:	PMake

Do not lie that debugging .for loops is a no-op.
2002-10-29 09:48:49 +00:00
David E. O'Brien
26f06d8b13 Mostly support alternate manpage zipping. 2002-10-29 09:20:22 +00:00
Juli Mallett
85779f0ead Split var.c into var.c and var_modify.c and move all the modification funcs
to var_modify.c, for readability.  constify some low hanging fruit (string
manipulation functions) and the upper layers appropriately.  No longer use
the private strstr(3) implementation, while changing string code.

Tested by:      lots of successful make buildworld.
2002-10-28 23:33:57 +00:00
Dag-Erling Smørgrav
eb87c5a73a Don't complain about not knowing the remote file size when working in
quiet mode.

PR:		bin/37079
Submitted by:	Nicolas Rachinsky <list@rachinsky.de>
2002-10-27 17:33:08 +00:00
Dag-Erling Smørgrav
97727a7dc1 Whitespace and indentation cleanup. 2002-10-27 15:32:51 +00:00
Dag-Erling Smørgrav
0c6d34af10 Forgot to disable alarms after fetchXGet() in previous commit. 2002-10-27 15:32:06 +00:00
Dag-Erling Smørgrav
dc161d5582 Add an ETA timer that kicks in after 30 seconds.
Re-add alarm(2) calls around the calls to fetchStat(3) and fetchXGet(3),
since these calls can still time out on DNS lookups or TCP connect(2).

Remove the alarm(2) calls in the main loop, since all methods properly
handle transfer timeouts (as opposed to connection timeouts).

Set the sigalrm flag if a timeout occurs in the main loop.

Move the signal: label up a little so we still set the atime and mtime
when the transfer times out or is interrupted, so that restarted transfers
will work as expected (as long as the file still exists).

MFC after:	2 weeks
2002-10-27 15:15:13 +00:00
Garrett Wollman
8dcb75fc8d Remove unnecessary compatibility macro. (We were only printing, not parsing,
intmax_t.)
2002-10-27 04:14:08 +00:00
Garrett Wollman
11e3dcb669 Add new 1003.1-2001/TC1/D6 parameters. (On final recirculation ballot now,
so this should be officially TC1 before the New Year.)

Add TrustedBSD pathconf parameters.

Add compilation support for -stable (to be merged momentarily).
2002-10-27 04:10:34 +00:00
Doug Barton
7d5b77ef5f Adjust the size passed to readlink so that the null termination
falls within the range of the path variable.

Cribbed from the latest NetBSD source.

Obtained from:	provos@NetBSD.org
2002-10-25 07:26:36 +00:00
Juli Mallett
5d46839577 Fix problem with my ability to tell the difference between 'r' and 'l'... We
want to check var[1], not val[1].

Submitted by:	Mark Valentine <mark@thuvia.demon.co.uk>
Pointed out by:	sam
Pointy hat to:	jmallett
2002-10-24 20:37:58 +00:00
Juli Mallett
85ec8fdb1d When expanding a specific [1-char] variable, only expand said specific
[1-char] variable.  Don't just automatically expand something which
starts with that character.

Obtained from:	OpenBSD [3 years ago!]
2002-10-24 12:57:42 +00:00
Juli Mallett
775fb1e81e Duplicate the variable name in the v->name field, as otherwise it points to
data that will be modified.  And do the appropriate thing now and free the
v->name buffer along with other relinquished memory.

XXX There is duplication here of destroying a Var, which is probably bogus,
and probably missed in a few places.
2002-10-24 04:10:55 +00:00
Juli Mallett
cbfcb39874 Remove efree(), it isn't used consistently enough to even pretend that it
might help on the systems it could possibly be used as a bandaid for.  In
fact, the only thing it's useful for is instrumenting free(3) calls, and in
that capacity, it's better served as a local patch, than a public wrapper.
2002-10-23 23:16:43 +00:00
Mark Murray
3c284de5a5 Change the type of an unused variable to appease a warning. 2002-10-23 19:10:15 +00:00
Mark Murray
a09114536e Adjust for getbsize argument type change. 2002-10-23 19:02:17 +00:00
Mark Murray
4b51efd2b3 Remove unneeded function prototypes. 2002-10-23 16:20:12 +00:00
Ruslan Ermilov
642b1db169 Need to run lint1 from ${WORLDTMP}/usr/libexec during buildworld.
Spotted by:	fjoe
2002-10-23 12:05:27 +00:00
Robert Watson
1494905bb6 Add a new '-s' option to su(1): if the flag is present, attempt to
also set the user's MAC label as part of the user credential setup
by setting setusercontext(3)'s SETMAC flag.  By default, change only
traditional process properties.

Approved by:	re
Obtained from:	TrustedBSD Project
Sponsored by:	DARPA, Network Associates Laboratories
2002-10-23 03:19:34 +00:00
Juli Mallett
1d5e8e35b5 De-obfuscate and correct the include path handling for SysV style includes.
PR:		32759
Submitted by:	Mark Valentine
Reviewed by:	Matthew Emmerton" <matt@gsicomp.on.ca>
MFC after:	15 days
2002-10-23 01:57:33 +00:00
Andrey A. Chernov
72d26fe4c9 Use more verbose diagnostics for wrong DIGIT range 2002-10-20 23:09:26 +00:00
Andrey A. Chernov
4bcccb2ebd Add checks for DIGIT set consistency to prevent common misinterpretation
automatically.
Remove output file on error.
Staticize functions declared as static.
2002-10-20 19:56:15 +00:00
Tony Finch
2441656486 Improve the way base64 mode is enabled based on the program name,
so that it works when the path to b64encode is used to run it.
2002-10-20 14:18:25 +00:00
Tilman Keskinoz
8d9e008a2e Add my birthday.
Approved by: kris (mentor)
2002-10-20 13:33:45 +00:00
Greg Lehey
6c8733c2a3 Sort by date. 2002-10-20 02:20:31 +00:00
Greg Lehey
c398fe500e Clarify holidays which apply only to the USA
Clarify that the USSR no longer exists, but some of the holidays are
celebrated anyway.

Reviewed in part by:	ru

Remove Jewish and most Muslim holidays.  They're all wrong, since they
don't apply to the Western calendar.  The much more complete Jewish
holidays are in calendar.judaic.  The Muslim holidays need to be
collected into a file, but there's not much point in having the wrong
date.

Remove many Fiji holidays.  They change every year by Government
decree, and some were duplicated as a result.

Remove some duplicates.

There's still a lot to be done; in particular, I think the Japanese
and British holidays are very inaccurate.  This file needs checking by
people who know the details.
2002-10-20 02:12:46 +00:00
Maxim Sobolev
d1cf9ea2c4 Fix a problem with RTLD_TRACE flag to dlopen(3), which sometimes can return
even if there was no error occured (when trying to dlopen(3) object that
already linked into executable which does dlopen(3) call). This is more
proper fix for `ldd /usr/lib/libc.so' problem, because the new behaviour
conforms to documentation.

Remove workaround from ldd.c (rev.1.32).

PR:		35099
Submitted by:	Nathan Hawkins <utsl@quic.net>
MFC after:	1 week
2002-10-19 10:18:29 +00:00
Ruslan Ermilov
b17996a47e Revert last delta. SGR support in grotty(1) is disabled system-wide
in /usr/share/tmac/troffrc pending the issue resolution on -arch.
2002-10-18 09:14:17 +00:00
Mark Murray
ed5fc39f22 When a user gets refused because the password is wrong, use the
older "BAD SU" syslog message that folks prefer. There is quite
a bit more tweaking that can be done with other similar messages.

Asked for by:	tjr
2002-10-18 08:23:24 +00:00
Adam Weinberger
f56d5f6047 Add myself
Approved by:	pat (mentor)
2002-10-18 07:50:46 +00:00
Tom Rhodes
aa82a338b0 Everyone else is doing it! (adding their birthdays) 2002-10-18 06:21:09 +00:00
Maho Nakata
918fbb9dc8 New committer's first commit(birthday). 2002-10-18 05:48:55 +00:00
Daichi GOTO
db87339a52 New committer first committion.
addition my birthday.
2002-10-18 04:56:03 +00:00
Tim J. Robbins
505b28166c Style: use sa_handler instead of __sigaction_u.__sa_handler. 2002-10-17 23:32:44 +00:00
Philippe Charnier
b9a86ec995 Use .Fl/Ar for flags and arguments. 2002-10-17 13:04:49 +00:00
Philippe Charnier
44f219ea75 Introduce option enumeration the standard way. 2002-10-17 12:58:14 +00:00
Mark Murray
d8456c7ada Dekerberise. The corresponding userland stuff has been dekerberised
for ages, and no-one seems to have noticed. Viva PAM!
2002-10-16 16:10:46 +00:00
Mark Murray
31f3117741 Dekerberise. The corresponding userland stuff has been dekerberised
for ages, and no-one seems to have noticed. Viva PAM!

Fix some easy/trivial warnings while I'm here.
2002-10-16 16:09:05 +00:00
Philippe Charnier
a1843ba8bc Add section number to .Xr directive. 2002-10-16 15:46:43 +00:00
Philippe Charnier
1878217deb The .Nm utility 2002-10-16 15:38:28 +00:00
Philippe Charnier
f4cda4bb8f Introduce enumerate of options using the standard way.
Remove .Pp between items.
2002-10-16 15:32:16 +00:00
Philippe Charnier
bcbf58952c Introduce enumerate of options using the standard way: 2002-10-16 15:28:20 +00:00
Philippe Charnier
e72bbdf42e Do not reuse flag name in its definition. Remove inadequate sentence. 2002-10-16 15:17:38 +00:00
Philippe Charnier
dc51023cb3 Spelling 2002-10-16 13:58:39 +00:00
Philippe Charnier
97fa9b7739 Remove done() which was just exit() so use of warn()/err() can be made. Abort
on allocation failure instead of displaying a warning and deferencing NULL
pointer after. Spelling. Add prototypes. Add list of option in synopsis section
of man page, -d is not referenced because available as a compile option. It
should be made a runtime option btw.
2002-10-16 13:50:09 +00:00
Alexey Zelkin
84cb77d4aa Add locale(1). I have used it for while as useful debugging tool
for locale related things.  So, I think it could be useful for
others.  It's not yet implement (or implement in different manner)
all POSIX things, but I think it's good enough for start.

POSIX conformance related updates and manpage to follow relatively soon.
2002-10-16 13:17:18 +00:00
Philippe Charnier
b94f6635c3 Normalize FILES section by using .Bl/.El enumerate. 2002-10-16 13:00:42 +00:00
Philippe Charnier
8a9d51c4f8 Test getopt() against -1 instead of EOF. 2002-10-16 12:56:22 +00:00
Philippe Charnier
6dc4364cd6 Spelling. 2002-10-16 12:42:15 +00:00
Philippe Charnier
5dd6a31588 Do not repeat option name in its definition. Use .Nm. In the sequence ``~.'',
``.'' is not a sentence termination, it must be escaped to be put inside
quotes.
Abort if execv() fails by adding err(). Do not dot terminate error messages.
2002-10-16 12:33:14 +00:00
Poul-Henning Kamp
0845b8fa43 Be consistent about functions being static.
Spotted by:	FlexeLint
2002-10-15 18:24:31 +00:00
Joerg Wunsch
75e861d635 Add information about the SDLT density codes.
Submitted by:	"Stewart MacLund" <sundie@lunaticfringe.org>
MFC after:	1 week
2002-10-15 12:53:29 +00:00
Poul-Henning Kamp
81af0b570e Remove an unused variable. 2002-10-14 08:54:08 +00:00
Tim J. Robbins
b5513cdbda Add Big5, MSKanji and UTF-8 to the list of supported encodings.
Mark UTF2 as being deprecated.
2002-10-14 00:45:51 +00:00
Greg Lehey
8842769832 Clarify that a number of incidents relate to Germany.
This file contains a number of incidents which do not related to
Germany.  It's not clear whether they should remain or not, so I have
left them.
2002-10-14 00:45:13 +00:00
Anders Nordby
0776ef23ca Add self. 2002-10-12 18:10:13 +00:00
Juli Mallett
760ddd8c1e The -a and -d flags are mutually exclusive, show them as such in usage() and
manual page for showmount(8)

Sponsored by:	Bright Path Solutions
MFC after:	2 weeks
2002-10-12 05:45:01 +00:00
Greg Lehey
afe401e3de Clarify details of the birth of Richard I of England. 2002-10-12 00:42:34 +00:00
Mike Barcroft
2b7f24d210 Change iov_base's type from char *' to the standard void *'. All
uses of iov_base which assume its type is `char *' (in order to do
pointer arithmetic) have been updated to cast iov_base to `char *'.
2002-10-11 14:58:34 +00:00
Olivier Houchard
a93cc5a1e7 Add myself.
Reviewed by:	mux (mentor)
2002-10-11 13:06:42 +00:00
Ruslan Ermilov
65b1f0f74e Groff 1.18.1 comes in with ANSI color support, enabled by default.
In "nroff" mode, italic font renders as an underlined text, which
makes it indistinguishable from the bold text on color monitors
(cons25 terminal type), yet it requires the less(1)'s -R option.
(Refer to the new grotty(1) manpage for details.)

So turn off the color support for now (when generating catpages),
until we figure out what do we do with this new feature.  I have
a patch for grotty(1) that tells it to use the "reverse video"
attribute to render the italic font.  Once this is accepted, we
can turn color support back on (if there won't be any objections
from the community).
2002-10-11 09:16:24 +00:00
Juli Mallett
f8137bcf93 Move utilitarian routines to util.c, which isn't the same as the old
compatability-geared util.c.  These are things like message printers
and the PrintAddr function for traversing lists.  Other general-purpose
utilities inside make(1) can go here, in time.
2002-10-10 19:27:48 +00:00
Juli Mallett
4526ed6ffb Convert make(1) to use ANSI style function declarations. Variable
documentation already adequatedly existed in the description in most
cases.  Where it did not, it was added.  If no documentation existed
beforehand, then none was added.  Some unused dummies for use in the
traversal functions were marked as __unused during the conversion.
Occasionally, local style fixes were applied to lines already being
modified or influenced.

Now make(1) should always build with WARNS=3.
2002-10-09 03:42:10 +00:00
Juli Mallett
0ce3fbf191 Use __FBSDID in the lst.lib files, to match to main make(1) files. It is
defined to __RCSID when bootstrapping, by the Makefile, but this change is
for consistency
2002-10-09 02:00:22 +00:00
Juli Mallett
15c11220ee Remove extern declarations from functions and source files where they would
happily fit into headers.
2002-10-09 01:56:02 +00:00
Juli Mallett
cf382f5bb1 Remove unused local-locals, where upper-level locals may safely be used. 2002-10-09 01:51:00 +00:00
Juli Mallett
7e75296d52 Reference the correct local variable in all parts of a for loop, so we
operate on the correct data (properly).

Tracked down by:	Dan Nelson
2002-10-08 21:29:04 +00:00
Tim J. Robbins
363a99169a Re-add the code which maps POSIX standard library names into the ones
FreeBSD uses; f.e. -lpthread -> -pthread, -lxnet -> nothing.
2002-10-08 02:19:54 +00:00
Tim J. Robbins
98c59a0ae1 Add the c99(1) utility, which is nothing more than a synonym for
cc -std=iso9899:1999 -pedantic, and is required by SUSv3.

PR;	36087
2002-10-07 09:37:55 +00:00
Kris Kennaway
b241e69d12 Use strlcpy() instead of strcpy() to not overflow static buffers. 2002-10-06 23:52:06 +00:00
Mike Barcroft
1d631f7ef1 Don't depend on <signal.h> to include <sys/time.h>, instead include
<sys/time.h> directly.  This is mostly bogus since CLOCK_REALTIME
should be defined in <time.h>, which these files already include.
2002-10-06 21:46:04 +00:00
Poul-Henning Kamp
5fd43411f3 Give make(1) the ability to use KQUEUE to wait for worker processes
instead of polling for them.

Unfortunately we cannot enable it yet because it panics the kernel
somewhere in kqueue.

Submitted by:	Stefan Farfeleder <e0026813@stud3.tuwien.ac.at>
2002-10-04 20:30:03 +00:00
Tim J. Robbins
26cabd19d5 Fix off-by-one error processing the line after an empty line when the
-a option is not specified.

Submitted by:	schweikh
MFC after:	1 week
2002-10-04 16:45:25 +00:00
Johan Karlsson
208464c323 Actually implement gzip's -c option. minigzip now also doubles
as zcat properly.

PR:		13043
Submitted by:	Toshihiko ARAI <toshi@jp.freebsd.org>
		Jonathan Towne <jontow@twcny.rr.com>

Approved by:	peter, sheldonh (mentor)
MFC After:	2 weeks
2002-10-03 19:30:22 +00:00
Juli Mallett
80ce40f394 In lieu of a good way to prevent every possible looping in make(1), stop
there from being more than 500 processes forked by make(1), to prevent a
forkbomb from happening, in a dumb and mechanical way.

PR:		alane
Submitted by:	bin/42772
MFC after:	2 weeks
2002-10-03 04:32:47 +00:00
John Baldwin
0d6326492b Catch up to SMTX -> SLOCK changes. 2002-10-02 20:33:52 +00:00
Juli Mallett
03f3a2a645 Code that has been #if0'd with the comment "WHY" since revision 1.1 can
disappear.
2002-10-02 16:06:39 +00:00
Juli Mallett
0b6a3508ac Remove 6-years-stale #if0, the behaviour isn't ever going to be limited to
compatible mode, as far as I know, since we use it...
2002-10-02 16:03:26 +00:00
Peter Pentchev
ac6d1c224f Teach ncal(1) about month names specified on the command line.
Reviewed by:	-audit
Approved by:	silence on -audit
MFC after:	3 weeks
2002-10-02 12:31:10 +00:00
Dima Dorfman
d427d1cc26 Remove some #if 0'd code. After this, a "make unifdef" here produces
no changes (against crypto telnet).

Reviewed by:	MD5
2002-10-02 00:37:01 +00:00
Dima Dorfman
0d7e18c3e1 Merge from crypto telnet: permit the argument to -s to be a hostname. 2002-10-02 00:29:34 +00:00
Juli Mallett
40eecdba73 Fix spurious three-space indentation in a four-space indentation file. 2002-09-29 00:20:28 +00:00
Juli Mallett
3873e563fc Fix ability to use csh(1) as the make(1) shell.
Sponsored by:	Bright Path Solutions
2002-09-29 00:02:04 +00:00
Juli Mallett
763d9eb177 Make make(1) WARNS=6 clean except for const issues. This mostly involves
renaming variables to not shadow libc functions or greater scope locals.  Kinda
makes one wonder if the extern ones weren't meant in some of these places :)

The only thing I'd still like to do WRT this is possibly combine rstat and
status in compat.c -- that should be fine, as I do not think the codepaths
will want both around at once.

Sponsored by:	Bright Path Solutions
2002-09-28 23:35:07 +00:00
Juli Mallett
76e8db31fc Fix merge error in previous commit.
Sponsored by:	Bright Path Solutions
2002-09-28 20:04:17 +00:00
Juli Mallett
1e3d8881cf Add empty default cases where they should be, remove non-local execution stuff
in compat.c which doesn't even have preprocessor-conditional-hidden support
code, and add a debugging statement where we might end up with a nil list
somehow, but where I doubt it.

First confirmed userland kill for Flexelint.

Sponsored by:	Bright Path Solutions
2002-09-28 20:03:26 +00:00
Poul-Henning Kamp
ca916247cd Rename struct specinfo to the more appropriate struct cdev.
Agreed on:	jake, rwatson, jhb
2002-09-27 18:27:10 +00:00
Ruslan Ermilov
2420b40463 Document the parsing bug. 2002-09-27 09:21:07 +00:00
Juli Mallett
a08239b5d0 Remove a semicolon that appears to be a lie.
Spotted by:	SPARC64 make WARNS=3
Sponsored by:	Rachel Hestilow <rachel@jerkcity.com>
2002-09-26 06:44:30 +00:00
Juli Mallett
cac04057f2 When formatting the time for a target, use %H instead of %k, which is mostly
the same, but uses a non-extension option.

Sponsored by:	Rachel Hestilow <rachel@jerkcity.com>
2002-09-26 06:40:04 +00:00
Juli Mallett
4fed818c7e Don't declare things as extern when they will be static.
Sponsored by:	Rachel Hestilow <rachel@jerkcity.com>
2002-09-26 01:39:22 +00:00
Mark Murray
4a63284e80 Unifdef(1) the crypto telnet sources. 2002-09-25 07:53:29 +00:00
Tony Finch
36076c1e7b The spec says that unifdefall removes all #ifs, and this now requires
the -k flag to unifdef.
2002-09-24 19:50:03 +00:00
Tony Finch
981dbf5bac The readability is improved by reducing the use of the passive voice.
No changes to the meaning are made.
2002-09-24 19:48:39 +00:00
Tony Finch
352d0a6932 It is probably a bad idea to unconditionally process directives with
constant controlling expressions: in particular, removing #if 0 sections
is considered "rude". This commit changes the default so that such
things are passed through unchanged, and the old behaviour can be had
with the -k "kill konsts" flag.

Suggested by:	markm
MFC after:	3 weeks
2002-09-24 19:27:44 +00:00
Andrey A. Chernov
73be6d69ef Make it work with POSIX sort (POS arg).
All old sorts understand -k too.
2002-09-24 19:05:40 +00:00
Andrey A. Chernov
197442ec02 Make it work with POSIX sort (POS arg)
All old sorts understand -k too.
2002-09-24 18:16:36 +00:00
Juli Mallett
5a4ba400c1 Use some macro evil to create the functions for using sysctl(3) to get each
variable natively.  It should allow you to use any sysctl mib set, but due
to limitations of what I can do with macros, right now it's limited to two,
which is all this program used anyway.

Sponsored by:	Bright Path Solutions
2002-09-23 06:47:39 +00:00
Juli Mallett
2ee166b2bd Check to see if we should print a space, rather than using the annoying
prefix methodology.  Adjust nearby style.

Sponsored by:	Bright Path Solutions
2002-09-23 06:14:13 +00:00
Jeff Roberson
cba1f1e079 - Add the -i option to read in a saved ktr file output by KTR_ALQ. 2002-09-22 07:21:28 +00:00
Greg Lehey
8c6bc30900 Update equinoxes and solstices.
PR:	bin/43166
2002-09-22 01:53:18 +00:00
Garrett Wollman
0d3bcc2e80 Make the threatened fts(3) ABI fix. FTSENT now avoids the use of the struct
hack, thereby allowing future extensions to the structure (e.g., for extended
attributes) without rebreaking the ABI.  FTSENT now contains a pointer to the
parent stream, which fts_compar() can then take advantage of, avoiding the
undefined behavior previously warned about.  As a consequence of this change,
the prototype of the comparison function passed to fts_open() has changed
to reflect the required amount of constness for its use.  All callers in the
tree are updated to use the correct prototype.

Comparison functions can now make use of the new parent pointer to access
the new stream-specific private data pointer, which is intended to assist
creation of reentrant library routines which use fts(3) internally.

Not objected to in spirit by: -arch
2002-09-21 01:28:41 +00:00
Eric Melville
b81df0819d Initialize a variable in order to fix when faced with picky compilers.
Sponsored by:	Apple
2002-09-20 19:40:23 +00:00
Ruslan Ermilov
f61bf05438 Update for FILE v3.39. 2002-09-19 13:53:17 +00:00
Ruslan Ermilov
751ec0537d Bootstrapping aid for systems without <stdint.h>.
(Needed to build mkmagic in build-tools.)
2002-09-19 12:30:34 +00:00
Garrett Wollman
e9cfb9ae3a Completely revamp the way getconf(1) works, for better adherence to the
intent of the Standard.

- Make getconf able to distinguish between configuration variables which
  are entirely unknown and those which are merely not defined in the
  compilation environment.  The latter now get a more appropriate
  "undefined\n" result rather than a diagnostic.  This may not be
  exactly right, but it's closer to the intent of the Standard than
  the previous behavior.

- Support ``programming environments'' by validating that the environment
  requested with the `-v' flag is the one-and-only execution environment.
  (If more environments are supported for some platforms in the future,
  multiple getconf(1) executables will be required, but a simple edit in
  progenv.gperf will enable automatic support for it.)  Document POSIX
  standard programming environments.

- Add all of the 1003.1-2001 configuration variables.  FreeBSD does not
  support all of these (including some that are mandatory); getconf will
  later be fixed to break the world should a required variable not be
  defined.

As a result of all these changes, gperf is no longer adequate.  Keep the
overall format and names of the files for now, to preserve revision history.
Use an awk script to process the .gperf files into C source, which does a
few things that gperf, as a more general tool, cannot do.  The keyword
recognition function is no longer a perfect hash function.

This may obviate the need for gperf in the source tree.

- Add a small compile-time regression test to break the build if any of the
  .gperf files declare conflicting token sets.  (gperf itself would have done
  this for the simple case of duplicate tokens in the same input file.)
2002-09-19 03:39:03 +00:00
Brian Feldman
873caac499 Update the usage string in the limits(1) manpage to include -b for
sbsize. Also, correct the format string in getopt(3) usage to reflect
that -b takes an argument, and correct another case of RLIMIT_SBSIZE
having been forgotten.
2002-09-18 16:25:59 +00:00
Juli Mallett
2dbb6cf1cb Make the DEBUGF() macro portable by (ugh) adding a Debug() function, which
is merely printf() but to stderr.  This takes care of the caveat which lead
to the use of a vararg macro -- getting everything to stderr.
2002-09-18 16:13:03 +00:00
Mike Barcroft
d0505643e5 ARIN has annoyingly started using caps when referencing
whois.apnic.net.  To properly receive hints for recursive IP searches,
we convert a buffer to lowercase before searching for magic words.

PR:		42834
Submitted by:	Andre Albsmeier <andre.albsmeier@mchp.siemens.de> (mostly)
X-MFC-After:	re approval
2002-09-18 07:51:46 +00:00
Juli Mallett
bed4636e02 Mostly rewrite the flag handling of uname(1) to be overridable, such as:
freefall% uname -s
  FreeBSD
  freefall% env UNAME_s=Linnex ./uname -s
  Linnex

MFC after:	1 month
2002-09-18 04:33:10 +00:00
Garrett Wollman
f002cffd7e Make obrien happy. Add a bad awk script which emulates as much of
gperf's behavior as we ever actually needed here.  This generates
a much-less-efficient keyword recognizer, but it's not like that matters
in this application.  Makefile changes coming once this passes the world
test.
2002-09-18 03:15:25 +00:00
Juli Mallett
cdba64071c Move common use of if (DEBUG(FOO)) printf... to DEBUGF(FOO, ...), using
variable length arguments to a macro.  Bump version as this makes DEBUG
statements *always* go to stderr rather than sometimes stdout.  There are
a few stragglers, which I will take care of as soon as I can.  Mostly these
relate to the need-for-death-of some of the remote job code.

Nearby stylistic nits and XXX added/fixed where appropriate.
2002-09-17 22:31:26 +00:00
Juli Mallett
37721c8309 #define<space> -> #define<tab> 2002-09-17 21:29:06 +00:00
Juli Mallett
0fd9fa89a9 Print debugging from DEBUG(VAR) level to stderr. About to macroise this.
(Read: More commits to come).

MFC in:		4 days.
2002-09-17 21:26:57 +00:00
Peter Wemm
66422f5b7a Initiate deorbit burn for the i386-only a.out related support. Moves are
under way to move the remnants of the a.out toolchain to ports.  As the
comment in src/Makefile said, this stuff is deprecated and one should not
expect this to remain beyond 4.0-REL.  It has already lasted WAY beyond
that.

Notable exceptions:
gcc - I have not touched the a.out generation stuff there.
ldd/ldconfig - still have some code to interface with a.out rtld.
old as/ld/etc - I have not removed these yet, pending their move to ports.
some includes - necessary for ldd/ldconfig for now.

Tested on: i386 (extensively), alpha
2002-09-17 01:49:00 +00:00
Bruce Evans
38c8f73ed0 Backed out revs 1.32-1.33. The problem has been fixed better by
depolluting <netinet/if_gre.h> in the !_KERNEL case.

Reviewed by:	sobomax
2002-09-16 10:06:02 +00:00
David E. O'Brien
8c8b4375bb Update for version 3.39. 2002-09-16 06:31:49 +00:00
David E. O'Brien
fc89e1e61a Update for 3.39. 2002-09-16 06:22:04 +00:00
Nate Lawson
e47c217844 Userland changes to go with vnode->v_tag change. 2002-09-14 18:51:10 +00:00
Peter Wemm
155c182a5c Promote gcore from i386-specific to the MI section.
Compiled on: alpha, sparc64, ia64
2002-09-13 18:29:08 +00:00
Peter Wemm
9e0a9e9833 Add #include <sys/queue.h> for sparc64's benefit. The MD includes there
have less polution.
2002-09-13 18:24:59 +00:00
Peter Wemm
e0491636b5 Use a crowbar to move the a.out code out of gcore.c and into its own
file so that we have a chance of using gcore on non-i386 platforms.  Use
linker sets to reduce the registration glue.  Remove md-sparc.c, we do not
have an a.out sparc32 port.  aoutcore.c was repocopied from gcore.c.
2002-09-13 16:33:35 +00:00
Mike Barcroft
1494fdadfb Some uses of the variable n needed to be int, others needed to be
size_t.  Add a new variable to cope.
2002-09-11 04:26:09 +00:00
Mike Barcroft
9654cb6531 Unbreak world by fixing 4 syntax errors and 1 wrong variable type. 2002-09-11 01:00:56 +00:00
Tony Finch
abfd963f3e Fix style bugs in macros. 2002-09-10 21:14:14 +00:00
Tony Finch
0987aa405b Tidy up the base64 code and relax the error handling. 2002-09-10 21:10:33 +00:00
Tony Finch
af08438611 Style: Don't treat pointers as booleans. 2002-09-10 20:53:46 +00:00
Tony Finch
e95d61f1c2 Fix tilde-expansion of the filename obtained from the "begin" line in -s
mode, and be more accurate about identifying begin lines so that spurious
ones don't have to be manually edited out, and be more forgiving about
errors so that -c mode is more useful.
2002-09-10 20:48:44 +00:00
Tony Finch
89f6a6d229 Replace a goto with continue. 2002-09-10 20:33:39 +00:00
Tony Finch
6ce2a155da Remove register keyword. 2002-09-10 19:23:44 +00:00
Tony Finch
c613756f77 Style: space after return. 2002-09-10 18:52:03 +00:00
Tony Finch
279c15995c Make the handling of -i neater. 2002-09-10 18:34:07 +00:00
Tony Finch
1e4cc34122 Only try to chmod the output if it's a regular file, rather than
hard-coding /dev/stdout as a special case.

Suggested by:	jmallett
2002-09-10 18:28:19 +00:00
Thomas Quinot
39449b2c8a Prevent the wrapper from looping on itself forever, when there
is a symbolic link in the PATH pointing back to /usr/bin/perl.

Change WARNS from 6 to 5 to account for the fact that sys/time.h,
included from sys/stat.h, produces a warning when compiled with
-pedantic.

PR:		bin/42418
Reviewed by:	roberto
2002-09-10 13:56:30 +00:00
Greg Lehey
f50b40bd4e Add the 1109 incident. 2002-09-10 00:07:19 +00:00
Jacques Vidrine
75bed0534a Check for FD_SET overrun. 2002-09-09 16:14:03 +00:00
David E. O'Brien
6c1739987a Catch up with the ISO-C++ standard.
Submitted by:	Craig Rodrigues <rodrigc@attbi.com>
2002-09-09 02:58:42 +00:00
Maxim Sobolev
3b68178c89 Also add #include <netinet/in_systm.h> before <neinet/ip.h> to fix the
world.

Submitted by:	Brooks Davis <brooks@one-eyed-alien.net>
2002-09-07 12:20:47 +00:00
Maxim Sobolev
885564890b Add #include <netinet/ip.h> in attempt to fix the world. 2002-09-07 06:16:22 +00:00
Archie Cobbs
1b69f09c39 Make it clear that the ":C" variable modifier expects an extended
regular expression instead of an obsolete regular expression.
Also, cross-reference re_format(7) instead of regex(3).

MFC after:	3 days
2002-09-06 17:33:11 +00:00
David Malone
a01e3379df Warns cleanups for netstat:
1) Include arpa/inet.h for ntohs.
2) Constness fixes.
3) Fix shadowing except for "sin" which shouldn't be in scope.
4) Remove register keyword.
5) Add missing initialsers to user defined structs.
5) Make prototype of netname6 globally visable.
6) Use right macros for printing syncache stats (even though entrie isn't
   a word).
2002-09-05 17:06:51 +00:00
Ian Dowse
56d037c684 Include stdint.h to make this compile.
Submitted by:	Garance A Drosihn <drosih@rpi.edu>
2002-09-05 07:43:34 +00:00
David Malone
f4ac32def2 ANSIify function definitions.
Add some constness to avoid some warnings.
Remove use register keyword.
Deal with missing/unneeded extern/prototypes.
Some minor type changes/casts to avoid warnings.

Reviewed by:	md5
2002-09-04 23:29:10 +00:00
David Malone
b073168829 Avoid a signedness warning by casting chain_index to a size_t.
(Should be OK as chain_index is supposed to be positive).
2002-09-04 21:22:49 +00:00
David Malone
2698bbe2da No need to declare optind as an external int. 2002-09-04 21:16:51 +00:00
Juli Mallett
c624d24df3 Die on -D=foo, when parsing options - we can't let someone define (nil).
MFC after:	3 days
2002-09-04 01:12:39 +00:00
Tony Finch
23a4f59e03 Don't try (and fail) to fchmod /dev/stdout. Revert the manual page
to suggest the portable alternative to -p.

PR:		42356
Submitted by:	Kimura Fuyuki <fuyuki@hadaly.org>
MFC after:	1 week
2002-09-03 19:37:23 +00:00
Tony Finch
59706ac3bb Suggest -p instead of -o /dev/stdout.
PR:	42356
2002-09-03 10:18:56 +00:00
Tony Finch
4023416250 Remove spurious whitespace 2002-09-03 09:58:11 +00:00
Ian Dowse
83c5a3b583 If the CC environment variable contains multiple words then split
it up into separate exec arguments.

Reviewed by:	markm
2002-09-01 12:49:27 +00:00
Peter Wemm
7b2f27b0fe Deal with bootstrapping from an old -current (almost exactly a year old)
which fails the make tests (doesn't understand ${notdef:U}) and therefore
fails on __FBSDID in usr.bin/make/*.  -DBOOTSTRAPPING is no help here since
this is before we are using the new share/mk/* files, and it would conflict
with the builtin -DBOOTSTRAPPING support later.. so use a different flag.
2002-08-31 07:18:40 +00:00
Andrey A. Chernov
c9887a654b Switch to new format which allows unlimited numbers of chains and
usually saves 2K in both data file and program memory.
Updated libc required.
2002-08-31 01:48:56 +00:00
Greg Lehey
6c4028203e Add dates of foundation for Malaya, Malaysia and Singapore. 2002-08-30 21:36:16 +00:00
Andrey A. Chernov
3ce74edd70 Prepare for switching to unlimited chains format 2002-08-30 20:34:36 +00:00
Greg Lehey
bdb9312632 Add date of foundation of Federal Republic of Germany.
Remove bogus event of 22 September 1953.

Submitted by:  Jan-Oliver Neumann <jneumann@ix.urz.uni-heidelberg.de>
2002-08-29 00:26:26 +00:00
Greg Lehey
959d9e0b51 - Clarify events which happened in the USA.
- Note that the USA has no King.
- Unify spelling "US", not "U.S.".
- Remove USSR holiday (anniversary of the revolution).
- Don't remove claim that the Federal Republic of Germany was founded
  in 1953 (22 September).  Somebody should clarify if something
  reallly did happen on that day.
2002-08-28 00:33:11 +00:00
Philippe Charnier
3c94f41f51 Do not repeat the name of the flag in its description 2002-08-27 19:14:08 +00:00
Philippe Charnier
835279c2c0 Use strchr() instead of index(). Use getopt(). Use err(). 2002-08-27 19:06:44 +00:00
Dag-Erling Smørgrav
dacff75286 s/optarg/s/ (cut'n'paste braino)
Spotted by:	kris
2002-08-27 10:19:24 +00:00
Greg Lehey
045d6370fc Clarify that the date 26 August 1920 was the date women got the vote
in USA, not the world first.

Add dates for women's votes in New Zealand.

Add dates for women's votes and rights to political office in South
Australia.
2002-08-26 00:23:56 +00:00
Philippe Charnier
93b0017f88 Replace various spelling with FALLTHROUGH which is lint()able 2002-08-25 13:23:09 +00:00
Juli Mallett
acdb9a105e Add a -C ala GNU make(1) for Makefiles which are too lazy to use $(MAKE) and
this particular GNU flag.  It changes into the given directory for the
operation in question.  This just goes into said directory at the time of
parsing the argument for getopt(3).

Submitted by:	Rachel Hestilow <rachel@jerkcity.com>
2002-08-25 02:45:04 +00:00
Andrey A. Chernov
7f4fd84cf9 Tweak chain example to show more possibilities 2002-08-23 14:03:59 +00:00
Sean Chittenden
d0d0355e4d Fix warning when calling w(1) when logged in via xdm/kdm. This is
really a problem with utmp/wtmp, but takes the same approach as who(1).

Reviewed by:	knu (mentor), mini, silence on -audit
Approved by:	knu (mentor), mini
2002-08-23 04:31:58 +00:00
Andrey A. Chernov
79458607f6 Allow chains in any form like <name1><name2> or \xf1\xf2, not binary
representation only.
2002-08-23 04:18:26 +00:00
Johan Karlsson
eb238d0692 Use correct document date for the -a option. 2002-08-22 01:54:18 +00:00
Johan Karlsson
1f05bc6c92 Add the -a option to report all matches instead of only the
first of each requested type.

Approved by: joerg, sheldonh (mentor)
2002-08-22 01:50:51 +00:00
Thomas Quinot
f763d3ef0a Jump in.
Reviewed by:	roberto
2002-08-21 21:18:14 +00:00
Joerg Wunsch
0dfcc59353 For scripts that are called in non-login environments (in particular
mail filters), the /usr/bin/perl dummy fails since it assumes that the
installed package could be reached via the existing $PATH.  Also,
since we are obviously looking for a perl installed by a package, we
should make sure that at least the default package bindir is being
searched.
2002-08-21 20:54:45 +00:00
Oliver Braun
feec8fd25b Add myself.
Approved by:	dwcjr (mentor)
2002-08-21 14:25:48 +00:00
Andrey A. Chernov
8011a282e0 Document SWIDTH* 2002-08-20 15:19:34 +00:00
Ruslan Ermilov
4612010cdd Allow embedded :' and !' in target names.
PR:		bin/6612
Obtained from:	OpenBSD
MFC after:	1 week
2002-08-20 12:50:32 +00:00
Warner Losh
84bbb6cab3 When login tries to do the chmod/chflags on a read only file system,
it complains that it can't do it because the filesystem is readonly.
Assume that when the user has a readonly /dev that they don't care if
login can't change the permissions/flags.  While this does break a few
things like msgs, we'll assume that the user setting up the read only
system knows what they are doing.

All this change does is to stop the complaint when the file system is
read only.  It also adds comments as to why EROFS and EOPNOTSUPP are
ignored.

This allows one to have a read-only / w/o a /dev MFS and have a
relatively warning-free existence.  /etc/rc still complains when it
can't chown/chflags/chmod things, but that's easy to ignore/tweak.

Reviewed by: roberto, phk
Sponsored by: Timing Solutions
2002-08-19 20:54:00 +00:00
Juli Mallett
3a7fc8ce59 Remove local prototypes for main(). 2002-08-19 03:07:56 +00:00
Juli Mallett
4a0193d39e Add a unary -not operator ala -false and !, for sake of completeness.
Obtained from:	OpenDarwin
MFC after:	1 week
2002-08-19 02:27:33 +00:00
Johan Karlsson
ad23c58318 Correctly handle empty path arguments, e.g., whereis -S -f biff.
Approved by:	joerg, sheldonh (mentor)
2002-08-18 18:21:18 +00:00
Michael C . Wu
ff9c912816 Add swidth definitions and lex code to mklocale
After adding swidth support in iswctype.c and ctype.h

Submitted by:	clkao@clkao.org
Reviewed by:	keichii,ache
Obtained from:	NetBSD
MFC after:	1 month
2002-08-16 13:46:43 +00:00
Sean Chittenden
ffd711039f Forgot to change branches for my src tree. MFS my birthdate.
Pointed out by:	maxim
Reviewed by:	knu (mentor)
Approved by:	knu (mentor)
2002-08-16 09:41:07 +00:00
Johan Karlsson
af3c8cb07d Bump document date for the 'beep only' change. 2002-08-16 03:08:25 +00:00
Joe Marcus Clarke
3bc63f613f Bah! Use the full name for Florida. 2002-08-15 22:44:56 +00:00
Joe Marcus Clarke
ed093a2098 Add myself. 2002-08-15 22:43:01 +00:00
David Greenman
25de38b6dc Add myself. 2002-08-15 22:34:45 +00:00
Juli Mallett
c9776a935f Oops, add -false to the operators list in the manual page for find(1), as added
in revision 1.17 of option.c.

MFC after:	1 week
2002-08-15 18:30:13 +00:00
Juli Mallett
65acff377a Add support for -false instead of '!' cause it can be hard to use that in
some shells, etc., and also for GNU compatability (lack of this broke the
Mono CVS build for me).

MFC after:	1 week
2002-08-15 18:24:55 +00:00
Doug Barton
782ce28781 I was too conservative with my header changes, so restore some sanity
via bde. atatat@NetBSD.org made basically the same change in their
version, so bring over their CVS Id which I neglected last time.

Obtained from:	bde, Andrew Brown <atatat@NetBSD.org>
2002-08-15 04:58:46 +00:00
Bosko Milekic
d8aadd88cf Unbreak building of fstat following version 1.23 of
src/sys/ufs/ufs/quota.h by including mount.h before ufs/quota.h.
2002-08-14 16:34:13 +00:00
Andrey A. Chernov
3b2d61780f Use proper #include 2002-08-14 11:59:57 +00:00
Andrey A. Chernov
02826007ca Add #undefs to separate local buffers declaration and now dinamic libc buffers 2002-08-14 11:51:26 +00:00
Ruslan Ermilov
93df249471 mdoc(7) police: simplify. 2002-08-14 11:38:30 +00:00
Ruslan Ermilov
eaa529121a mdoc(7) police: Forgot to bump .Dd. 2002-08-14 11:32:32 +00:00
Ruslan Ermilov
3791250688 mdoc(7) police:
Added -F and -W options to the SYNOPSIS.
Fixed options DESCRIPTION to match style(9).
Document the default for -F.
2002-08-14 11:31:37 +00:00
Ruslan Ermilov
67cb90ecd7 Fix the usage() to match style(9). 2002-08-14 11:28:07 +00:00
Ruslan Ermilov
d3ee5eafe5 mdoc(7) police: nits. 2002-08-14 11:05:40 +00:00
Doug Barton
a6d192950e A much better description of the -q option.
Obtained from:	Andrew Brown <atatat@NetBSD.org>
2002-08-13 20:07:36 +00:00
Ian Dowse
35655e3c45 If a timeout is specified, make sure that rcmd() completes within
the specified time. Previously, rsh could potentially hang indefinitely
at this point even when a timeout was set, for example if the server
accepts the connection and then never sends any reply.

PR:		bin/20042
Submitted by:	Keith White <Keith.White@site.uottawa.ca>
MFC after:	1 week
2002-08-13 16:25:38 +00:00
Ruslan Ermilov
a654c53e16 mdoc(7) police: Removed redundant .Ns calls. 2002-08-13 16:07:28 +00:00
Ruslan Ermilov
5e27573309 mdoc(7) police: untangle. 2002-08-13 15:59:28 +00:00
Doug Barton
5b812a140d A cooperative effort...
1. Update the code to the latest from NetBSD, which includes:
* A new command line option to suppress stat(2) errors
* Output is now done via stdio
* Fixes for bitwise OR'ing of letters

2. Andrew from NetBSD merged in our own Johan's readlink patches.

3. Andrew also merged in some brucifications.

I made some small contributions to the header cleanup, and tried
to generally improve the overall style(9)'ishness. I also documented
the new -q option and added the *LINKS to the Makefile.

All responsibility for mistakes in merging the contributions
from the above is mine.

Obtained from:	Andrew Brown <atatat@NetBSD.org>, bde, johan
2002-08-13 08:23:49 +00:00
Andrey A. Chernov
3e2322fcff Fix typing error in prev. commit 2002-08-12 17:24:42 +00:00
Andrey A. Chernov
09d932cf40 Fix style bug in prev. commit 2002-08-12 17:23:06 +00:00
Andrey A. Chernov
54c93e4f4d Fix su job control (recently introduced for PAM cleanup purposes) to not
kill login shell on either "suspend/fg" or "stop $$/fg" for tcsh. Since
this bug occurse on -stable too, it is not kernel threads bug.

Submitted by:	 David Xu <bsddiy@yahoo.com>
2002-08-12 10:49:01 +00:00
Jens Schweikhardt
2b239dd118 Fix typos; each file has at least one s/seperat/separat/
(I skipped those in contrib/, gnu/ and crypto/)
While I was at it, fixed a lot more found by ispell that I
could identify with certainty to be errors. All of these
were in comments or text, not in actual code.

Suggested by:	bde
MFC after:	3 days
2002-08-11 13:05:30 +00:00
Ruslan Ermilov
ef3a89cfe8 main.c:450: warning: `targs' might be used uninitialized in this function
Spotted by:	patrick@godloveya.com, naddy, -Wuninitialized

This segfaulted alpha and sparc64; i386 had this magically zeroed.
2002-08-11 11:10:43 +00:00
Tim J. Robbins
98c385e7d6 Locale environment variables influence wc(1) regardless of whether the
-m option is specified; correct ENVIRONMENT section.
2002-08-11 10:54:19 +00:00
Tim J. Robbins
e58245f7dc Use the iswspace(3) function now that it's been implemented. 2002-08-11 10:52:13 +00:00
Tim J. Robbins
13ee49d316 Correct boundary condition error in D' and P' commands when the last
line of the pattern space is empty. Don't emit spurious newline when
EOF is reached with the `N' command.

Pointed out by:	Oleg Osyka
MFC after:	1 week
2002-08-11 09:53:44 +00:00
Maxime Henrion
24befda40b Add #include <sys/sysctl.h>. In my tree, mount.h includes
sysctl.h and I was depending on this namespace pollution.

Submitted by:	jake
2002-08-11 02:07:43 +00:00
Maxime Henrion
5965373e69 - Introduce a new struct xvfsconf, the userland version of struct vfsconf.
- Make getvfsbyname() take a struct xvfsconf *.
- Convert several consumers of getvfsbyname() to use struct xvfsconf.
- Correct the getvfsbyname.3 manpage.
- Create a new vfs.conflist sysctl to dump all the struct xvfsconf in the
  kernel, and rewrite getvfsbyname() to use this instead of the weird
  existing API.
- Convert some {set,get,end}vfsent() consumers to use the new vfs.conflist
  sysctl.
- Convert a vfsload() call in nfsiod.c to kldload() and remove the useless
  vfsisloadable() and endvfsent() calls.
- Add a warning printf() in vfs_sysctl() to tell people they are using
  an old userland.

After these changes, it's possible to modify struct vfsconf without
breaking the binary compatibility.  Please note that these changes don't
break this compatibility either.

When bp will have updated mount_smbfs(8) with the patch I sent him, there
will be no more consumers of the {set,get,end}vfsent(), vfsisloadable()
and vfsload() API, and I will promptly delete it.
2002-08-10 20:19:04 +00:00
Jake Burkholder
d9ac5b20fb truss hasn't been ported to ia64 yet.
Noticed by:	ru
2002-08-10 06:10:17 +00:00
Jake Burkholder
9b9669488b xlint seems to build fine on sparc64. 2002-08-10 05:44:44 +00:00
Jake Burkholder
298f4dc3a2 Put getconf in the right place. 2002-08-10 05:43:40 +00:00
Thomas Moestl
95ba428ccb The boottime variable in sys/kern/kern_tc.c is a struct timeval, not a
time_t, so do not use the latter as type when retrieving the variable
via libkvm. This should fix vmstat on sparc64.
2002-08-09 15:47:43 +00:00
Ian Dowse
e56990e43b Add a new flag (-l) that suppresses quota checks on NFS filesystems.
PR:		bin/12939
Submitted by:	Neil Blakey-Milner <nbm@rucus.ru.ac.za>
2002-08-09 00:53:00 +00:00
Ian Dowse
e608ec61bd Fix a few compiler warnings, sort options and make the usage()
output match the synopsis.
2002-08-09 00:43:36 +00:00
Ruslan Ermilov
19d732af8b Pacify ``make -f /dev/null -V FOO''. 2002-08-07 13:25:51 +00:00
Matthew N. Dodd
fb034d05ac Remove an unnecessary cast. 2002-08-07 11:35:18 +00:00
Andrey A. Chernov
04a0be1f97 Back out workaround of fixing "suspend/fg" by price of breaking "stop $$/fg".
This is real kernel bug (threads) and don't attempt to mask it by
workarounds to increase chances to fix it in the kernel.
2002-08-07 05:44:50 +00:00
Matthew N. Dodd
37169f9446 - Use time.h not sys/time.h.
- Fix printf format errors.

Submitted by:	 bde
2002-08-06 12:46:14 +00:00
Greg Lehey
6dba302111 Remove Australia from list of locations supposedly having a bank
holiday on 6 August.  Since this claim isn't dependent on the weekday,
I have my strong doubts about the other locations too, but I can't
confirm, so I'm leaving them in.
2002-08-05 23:54:22 +00:00
Matthew N. Dodd
28c4ea6da8 Remove extra space in output. 2002-08-05 14:56:20 +00:00
Matthew N. Dodd
42a389ac3e Diff reduction. 2002-08-05 13:23:41 +00:00
Matthew N. Dodd
203098d816 Use timespec not timeval. 2002-08-05 12:22:55 +00:00
Jake Burkholder
f84c971a6f Ported to sparc64. 2002-08-04 17:57:01 +00:00
Bruce Evans
c69d844294 Include <sys/time.h> for the declaration of struct timeval. Do not
depend on namespace pollution in <signal.h>.  (truss shouldn't be
using timevals anyway, since it was implemented long after timevals
were obsoleted by timespecs.)
2002-08-04 10:57:41 +00:00
Matthew N. Dodd
9897b20356 Add options to print the argument and environment string parameters to
execve().

This could be done in a more general manner but it still wouldn't
be very pretty.

MFC after:	 3 weeks
2002-08-04 02:24:21 +00:00
Matthew N. Dodd
0629483c41 Add a "FreeBSD ELF32" entry to ex_types[]. 2002-08-04 02:20:06 +00:00
Matthew N. Dodd
88a6987d40 Terminate the output line when a non-returning syscall is printed. 2002-08-04 01:28:13 +00:00
Matthew N. Dodd
0d0bd00edd Add options to print absolute and relative timestamps.
PR:		 bin/25587 (in part)
MFC after:	 3 weeks
2002-08-04 01:27:31 +00:00
Matthew N. Dodd
c03bfcc871 Allow tracking fork()ed children.
PR:		 bin/25587 (in part)
MFC after:	3 weeks
2002-08-04 01:02:52 +00:00
Matthew N. Dodd
ec0bed25ba Parameterize globals.
PR:		bin/25587 (in part)
MFC after:	3 weeks
2002-08-04 00:46:48 +00:00
Robert Drehmel
6dbe8d53a5 Use a cast to `void *' before casting to a pointer to a structure
to stop GCC emitting warnings about increased alignment requirements
which broke the build for sparc64.

Approved by:	des
2002-08-02 11:57:59 +00:00
Dag-Erling Smørgrav
02bd9db045 Don't depend on namespace pollution from <netinet/in_pcb.h>.
Submitted by:	bde
2002-08-01 16:49:31 +00:00
Dag-Erling Smørgrav
1e6690e5db Implement the -l and -c options, which I'd forgotten. 2002-08-01 11:02:30 +00:00
Dag-Erling Smørgrav
ca007d9172 Rewrite sockstat(1) in C.
Sponsored by:	DARPA, NAI Labs
2002-07-31 12:32:03 +00:00
Tony Finch
d1691a2ff6 Fix some bugs in in-place editing:
(1) errors from freopen were not reported correctly
(2) large files were not handled correctly
(3) read-only files broke things

MFC after:	1 week
2002-07-30 19:42:18 +00:00
Tim J. Robbins
0467aed3c9 Ignore leading semicolons on commands; required by SUSv3.
Obtained from:	NetBSD (kleink, Aymeric Vincent)
2002-07-30 14:07:30 +00:00
Tim J. Robbins
6e9c52b638 When translating and -C is specified, behave as if the complemented set was
in the locale collating order as required by SUSv3.
2002-07-29 23:42:00 +00:00
Tim J. Robbins
482711cfa6 When translating and the -c option is specified, handle the case where the
second string argument is more than one character in length in the way
required by SUSv3 (and the way GNU textutils and SVR4 do it).
2002-07-29 14:50:54 +00:00
Ruslan Ermilov
d2893b161b Drop support for COPY, -c has been the default mode of install(1)
for a long time now.

Approved by:	bde
2002-07-29 09:40:17 +00:00
Ruslan Ermilov
33c1de7d1f Ignore -C, -p, and -S options of install(1) when used with the -d
option.  Warn about COPY being phased out.  Restore the old method
of always comparing before installing: INSTALL="install -C".

Requested by:	bde
2002-07-29 08:51:04 +00:00
Dag-Erling Smørgrav
35945a74ac fetch(1) is WARNS-5 clean (tested on i386 and Alpha) 2002-07-28 21:09:57 +00:00
Dag-Erling Smørgrav
32411a1b6f Use strtol(3) instead of a home-grown version, and fix a "possibly
unitialized variable" warning.
2002-07-28 21:09:25 +00:00
David Malone
50bb77244e Add enough consts to keep everyone happy. 2002-07-28 16:23:28 +00:00
David Malone
81b4504baa Don't reuse a const char * when we really want a char *. 2002-07-28 16:17:38 +00:00
David Malone
91fbb9c1db Improve WARNS situation for kdump:
1) Define _KERNEL while including sys/time.h to get some function prototypes.
2) Add prototypes and ANSIify definitions.
3) Constness changes.
4) Remove register keyword.
5) Actually return a sensible value from main.
6) Make fread_tail take a void * instead of a char *.
7) Avoid a signedness warning by casting to a size_t. Should be safe
   enough 'cos we also check for nonnegativity.
8) Be extra chummy with sigset_t rather than passing a struct to printf
   and pretending it is an int.
2002-07-28 16:05:07 +00:00
David Malone
c10b37bf7a ANSIify function definitions to avoid a warning. 2002-07-28 15:50:38 +00:00
David Malone
8015edeebb The return value of snprintf should be always nonnegative, so it should
be safe to cast it to a size_t before comparing it to a sizeof().
2002-07-28 15:41:15 +00:00
David Malone
47e9e6a168 ANSIify function definitions to avoid a warning. 2002-07-28 15:32:17 +00:00
David Malone
19817b8518 ANSIify function definitions to avoid a warning.
Minor constness changes.
2002-07-28 15:28:38 +00:00