Commit graph

3913 commits

Author SHA1 Message Date
Josef Karthauser 445f17bbee When displaying interface statistics with -i show a '-' for any
values that aren't updated for a particular network-layer address.
2001-03-04 22:25:05 +00:00
Bill Fumerola f5db5b7fcd BDECFLAGS.
while I'm here, fix bitrotted debug code generating template.
2001-03-04 12:28:57 +00:00
Andrey A. Chernov 2742fc8eb2 Preserve comma as separator when it is not equal to radix character 2001-03-03 16:47:07 +00:00
Andrey A. Chernov e25fd27cd1 Don't use "," as load avg. separator because it can be precision point in some
locales, so leads to confusion
2001-03-03 01:32:46 +00:00
Andrey A. Chernov 5f2de0a78a Oops, remove tabs sneaked in wrong place 2001-03-02 23:49:07 +00:00
Andrey A. Chernov 000346454c Use AM/PM time only when available in locale 2001-03-02 23:11:38 +00:00
Warner Losh 003ff9433b Add -g group to usage message.
Don't treat pointer as a boolean, but instead test it against NULL.
Add warning for groups that don't exist

Submitted by: ru
2001-03-02 07:30:37 +00:00
Warner Losh e829cbf262 Include -DDEFSHELL=1 in Makefile.dist so people boostrapping will
have a sane default.

Also add $FreeBSD$ while I'm here.

Pointed out by: bde
2001-03-01 06:26:32 +00:00
Warner Losh 20b367cea1 MAXPATHLEN includes the trailing NUL.
Correct array sizes to reflect this.
Correct NUL termination after strncpy.

# Didn't to strncpy -> strlcpy change.
2001-03-01 06:03:17 +00:00
Warner Losh 77892acd6a MAXPATHLEN contains the trailing NUL. 2001-03-01 06:00:22 +00:00
Warner Losh 167ea27b4f MAXPATHLEN is enough.
Also, snprinf is guaranteed by the new ansi standard to NUL terminate the
string, so we don't need to do that ourselves.
2001-03-01 05:52:38 +00:00
Daniel C. Sobral 5bf6254172 All temperature scales are centigrades. Use "Celsius" instead. 2001-03-01 05:51:46 +00:00
Warner Losh 470b24b584 MAXPATHLEN already accounts for the trailing NUL, so no need to add one in.
In addition, since we pass readlink MAXPATHLEN - 1, we would have never have
used that extra byte anyway.
2001-03-01 05:49:36 +00:00
Warner Losh 55ff3bf4be MAXPATHLEN includes the trailing NUL character, so there's no need to add 1
to it for the size of path.
2001-03-01 05:47:28 +00:00
Warner Losh 78de666777 Remove redundant declaration of optind. It has been declared in unistd.h
for ages.
2001-03-01 05:46:03 +00:00
Warner Losh 6a20d55a59 o Add support for wall -g. This will send a message to all members of
a given group.
o Minor code style cleanups while I'm here

Reviewed by: bde, kris, markm, audit@
2001-03-01 05:43:12 +00:00
John Hay b88a90fd4c The secure temporary directory is always created, so always remove it. 2001-02-28 19:21:44 +00:00
Ruslan Ermilov c2d03ea879 Eliminate mdocNG warnings caused by misplaced or extraneous macro calls. 2001-02-28 17:38:53 +00:00
Jonathan Lemon 6029e6933c Use EV_SET() macro to initialize kevent structure. 2001-02-28 16:16:31 +00:00
David Malone 357c2d78c4 Add missing prefix for nano, I presume this was missing 'cos of the
prefix recusrion bug. Remove units which can be derived using prefixes
and other units.

Add new prefixes for 2^10, 2^20, etc...
2001-02-28 16:00:32 +00:00
David Malone 17ad860f81 Give units a bit of a cleanup:
1) Fix a bug where the recursion on prefixes where if recusrion failed
	then the next attempt started too far along the string.
2) Up some internal limits that we were about to hit off.
3) Change the constness and signedness of some things and complete missing
	prototypes.
4) Remove the readerror function 'cos it could print out the wrong
	wrong file name. Replace it with more useful error messages.
5) Use sizeof when passing buffers to fgets.
6) Warn about empty prefix definitions.

Reviewed by:	iedowse
2001-02-28 15:57:38 +00:00
David E. O'Brien bc321b0e44 Update HISTORY. 2001-02-28 03:33:44 +00:00
David E. O'Brien 52608c9fbf Fix indent endless on garbage input (i.e., if it encountered EOF while
waiting for a '}' nesting terminator)

Obtained from:	OpenBSD rev 1.8
2001-02-27 20:50:34 +00:00
Andrew Gallatin 98e53e5bfb - An array of 4 32-bit ints for avenrun doesn't work on the alpha because
fscale is a (64-bit) long.  So just use a struct loadavg.
This fixes the recent failure of top on alphas:
	top: sysctl(vm.loadavg...) failed: Cannot allocate memory

- use size_t for sizeof() so as to fix a few int/long warnings on alpha

Reviewed by: Thomas Moestl <tmoestl@gmx.net>
2001-02-27 17:11:19 +00:00
Ruslan Ermilov f51cb008b7 mdoc(7) police: utilize .St macro. 2001-02-26 15:55:52 +00:00
Ruslan Ermilov 94ad6032c5 mdoc(7) police: restore correct order of references in the SEE ALSO. 2001-02-24 10:30:27 +00:00
Robert Watson 0ce14ceb84 Remove directive to install top as group kmem. Remove directive to
install top with setgid bit.
2001-02-23 18:55:43 +00:00
Robert Watson 39d513ecdd Adapt the top utility to not use kmem_read to retrieve variables now
available via sysctl().  As a result, top should now be able to run without
setgid kmem.

Submitted by:	Thomas Moestl <tmoestl@gmx.net>
Reviewed by:	freebsd-audit
2001-02-23 18:52:37 +00:00
Akinori MUSHA 7c1d4b3ae9 Implement the following options and primaries:
-E      Interpret regular expressions followed by -regex and -iregex op-
             tions as extended (modern) regular expressions rather than basic
             regular expressions (BRE's).  The re_format(7) manual page fully
             describes both formats.

     -iname pattern
             Like -name, but the match is case insensitive.

     -ipath pattern
             Like -path, but the match is case insensitive.

     -regex pattern
             True if the whole path of the file matches pattern using regular
             expression.  To match a file named ``./foo/xyzzy'', you can use
             the regular expression ``.*/[xyz]*'' or ``.*/foo/.*'', but not
             ``xyzzy'' or ``/foo/''.

     -iregex pattern
             Like -regex, but the match is case insensitive.

These are meant to be compatible with other find(1) implementations
such as GNU's or NetBSD's except regexp library differences.

Reviewed by:	sobomax, dcs, and some other people on -current
2001-02-23 16:20:55 +00:00
Alfred Perlstein 3cf714fef8 fix usage statement (add missing [-n devs] option)
Submitted by: Maxim Konovalov <maxim@macomnet.ru>

Silence a warning by renaming the 'pgtok' #define to 'vmstat_pgtok' so
as not to conflict with the 'pgtok' #define in sys/param.h
2001-02-22 13:55:12 +00:00
Garrett Wollman d75f6037c8 Reword the description a little bit more for parallel construction. 2001-02-21 19:33:38 +00:00
Garrett Wollman 046627251a Destroy the evidence of my misunderstanding of the specification.
Also fix up the phrasing in the man page a bit.
2001-02-21 19:31:53 +00:00
Kris Kennaway 0937df81ca Introduce support for using OpenSSL ASM optimizations. This is done
through the use of a new build directive, MACHINE_CPU, which contains a
list of the CPU generations/features for which optimizations are desired.
This feature will be extended to cover the ports tree in the future.

Currently OpenSSL provides optimizations for i386, i586 and i686-class
CPUs. Currently it has not been tested on an i386 or i486.

Teach make(1) to provide sensible defaults for MACHINE_CPU if it is not
defined (namely, the lowest common denominator CPU we support for each
architecture).  Currently this is i386 for the i386 architecture and ev4
for the alpha.  sys.mk also sets the variable as a last resort for
consistency with MACHINE_ARCH and bootstrapping from very old versions of
make.

Benchmarks show a significant speed increase even in the i386 case, with
additional improvements for i586 and i686 systems.  For maximum performance
define MACHINE_CPU=i686 i586 i386 in /etc/make.conf.

Based on a patch submitted by:  Mike Silbersack <silby@silby.com>
Reviewed by:    current
2001-02-19 03:59:05 +00:00
Peter Wemm 8d03543c79 Have yacc use a prototype for yygrowstack(void) on ANSI compilers.
This fixes a gcc warning with -Wmissing-prototypes.
2001-02-19 01:10:01 +00:00
Mark Murray a28d666c49 Adjust columns for wide nicenesses in 'top -S'. 2001-02-18 11:08:47 +00:00
Jeroen Ruigrok van der Werven d1d2ed0e78 Preceed/preceeding are not english words. Use precede and preceding.
Add $FreeBSD$.
2001-02-18 10:44:00 +00:00
Jeroen Ruigrok van der Werven d7d97eb0aa Preceed/preceeding are not english words. Use precede and preceding. 2001-02-18 10:43:53 +00:00
Luigi Rizzo 60846af2e6 Do not compile INET6 support if RELEASE_CRUNCH is defined
(used by install floppy/picobsd)
2001-02-18 07:28:31 +00:00
Bruce Evans 8b72aacc66 Fixed some style bugs (bogus cloned Id, null overrides of defaults, and
the usual style bugs for DPADD/LDADD).
2001-02-17 06:20:14 +00:00
Bruce Evans 58445af0f8 Removed some garbage (genassym(8) and its infrastructure). 2001-02-17 06:06:14 +00:00
Ian Dowse b654e1067b Fix `fstat -m' (show memory-mapped files), which was broken by
revision 1.25. When evaluating the termination condition for the
iteration over all map entries, we must take care to use the kernel
versions of all pointers. The code was comparing a kernel pointer
to a pointer within a local variable, so the loop never terminated.
2001-02-15 22:42:44 +00:00
Peter Wemm 69179c1439 Work around the p_comm[] size limit. If the user supplies more than
16 characters, only check the first 16 since that is all the kernel
records.  This isn't ideal, but it is probably the best we can do.
Otherwise, "killall communicator-linux-4.76.bin" will not match
the process as the kernel only records "communicator-lin".
2001-02-14 21:56:03 +00:00
Ruslan Ermilov 2855fa0467 mdoc(7) police: replace -hang list with the -tag list,
add missing .Xo/.Xc to the tags.  This only worked due
to the off-by-one bug in the -hang lists, which I will
hopefully backport from the mdocNG shortly.
2001-02-14 10:14:35 +00:00
Ruslan Ermilov 47dec78170 mdoc(7) police: use the default ``file ...'' feature of the .Ar macro. 2001-02-13 09:56:35 +00:00
Jake Burkholder 4c85452ba9 Catch up to new priority interface. 2001-02-12 00:21:38 +00:00
David Malone d3d8587299 Uname is in section 3 of the manual pages.
PR:		25008
Submitted by:	fullermd@over-yonder.net
2001-02-11 21:19:31 +00:00
Andrey A. Chernov 124d32d6a9 Change localizing to LC_ALL 2001-02-10 23:25:09 +00:00
Andrey A. Chernov e1fc0c16f0 Localize it (LC_NUMERIC) 2001-02-10 22:46:47 +00:00
Ruslan Ermilov 429d919c70 mdoc(7) police: mark LC_NUMERIC with .Dv. 2001-02-10 10:26:52 +00:00
Will Andrews 2de6a43d0a Fix nasty bug where make(1) assumed that you could read the directory it
was in.  This shall be MFC'd in about three days (probably not a good idea
to MFC the stylistic changes though - see below).

PR:		19978
Submitted by:	Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
Patch by:	roam (slightly modified by me to use NULL not NIL)
2001-02-10 07:12:18 +00:00
Andrey A. Chernov dc7d8c99d0 Localize it (LC_NUMERIC) 2001-02-10 06:49:53 +00:00
Jacques Vidrine 17ada68462 Fix login so that it exports environmental variables that are set by PAM
modules (via pam_putenv).  The following variables will never be set in
this fashion:

   SHELL, HOME, LOGNAME, MAIL, CDPATH, IFS, PATH
   any variable starting with `LD_'
2001-02-09 13:21:50 +00:00
Mike Heffner 8ecfa0142f Fix style(9) bugs from previous commit: remove space after function
names and revert to char *[].

bde by:	bde, imp
2001-02-08 20:15:59 +00:00
Alexey Zelkin 75c84bca41 Optimize gencat(1) sources in same manner as its libc part some time ago:
. remove SYSV compatibility bits
. sort #include's
. ifdef unused code
. cleanup BDECFLAGS warnings
. fixed few typos in diagnostics messages
. style(9) fixes

as part of this cleanup I have changed all K&R declarations to ANSI style.
Main reason for doing that was great mix of declarations used here - clean
ASNI , clean K&R, ifdef'ed (both).

Reviewed by:	ache (mostly)
2001-02-08 16:38:16 +00:00
David E. O'Brien b7b2701f13 Remove the manpage since the actual software was put in the Attic.
Noticed by:	bde
2001-02-08 09:30:21 +00:00
Mike Heffner 7a536c3b41 De-__P()-ify, convert K&R style declarations to ANSI ones 2001-02-08 05:58:55 +00:00
Mike Heffner aeacf525ad Prevent string overflows by using safer string functions
Use tolower() rather than bit or-ing
Sanity check user specified printf() format
Exit when too many input files are given
Remove register from variables

Reviewed by:	markm, imp
2001-02-08 05:33:19 +00:00
Ruslan Ermilov 46eea498da mdoc(7) police: Change -filled displays (which just happen
to be the same as -ragged in the current implementation) to
-ragged.  With mdocNG, -filled displays produce the correct
output, formatted and justified to both margins.
2001-02-07 13:45:30 +00:00
Philippe Charnier 4c86f3ad84 Spelling
Remove unused #includes
2001-02-06 20:13:48 +00:00
Philippe Charnier 39e21a1b64 Remove duplicate FreeBSD Id
Remoce unused #include
Use imperative mode to start flag description
2001-02-06 20:03:48 +00:00
Philippe Charnier 3a87eff1cf Rework diagnostics text
Remove unused #include
2001-02-06 20:01:40 +00:00
Ruslan Ermilov c7368f9305 mdoc(7) police: simplify construct. 2001-02-06 16:20:31 +00:00
Jeroen Ruigrok van der Werven 2fa72ea7d4 Fix typo: compatability -> compatibility.
Compatability is not an existing english word.
2001-02-06 12:05:58 +00:00
Jeroen Ruigrok van der Werven 1a6e52d0e9 Fix typo: seperate -> separate.
Seperate does not exist in the english language.
2001-02-06 11:21:58 +00:00
Jeroen Ruigrok van der Werven efe5a08e09 Fix typo: seperate -> separate.
Seperate does not exist in the english language.

Also add $FreeBSD$ to README.
2001-02-06 11:21:40 +00:00
Poul-Henning Kamp 6817526d14 Convert if_multiaddrs from LIST to TAILQ so that it can be traversed
backwards in the three drivers which want to do that.

Reviewed by:    mikeh
2001-02-06 10:12:15 +00:00
Jeroen Ruigrok van der Werven f09deb6962 Fix typo: wierd -> weird.
There is no such thing as wierd in the english language.
2001-02-06 09:25:10 +00:00
Jeroen Ruigrok van der Werven 67034ac6ad Fix tftpd and tftp to support file transfers of over 65535 blocks
(about 31 MB - 32 MB).

Submitted (partially)
	by: Pascal Hofstee <daeron@wit401305.student.utwente.nl>
2001-02-02 10:53:02 +00:00
Ruslan Ermilov d0353b836e mdoc(7) police: split punctuation characters + misc fixes. 2001-02-01 16:38:02 +00:00
Will Andrews 99557a7988 De-__P()-ify
Reviewed by:	markm
2001-01-28 00:35:40 +00:00
Will Andrews d8a3fbd50d BDECFLAGS: constify; use proper types. Add $FreeBSD$, clean up #ifndef lint.
Reviewed by:	markm
2001-01-28 00:34:29 +00:00
Alexey Zelkin 8b32114bd4 Fix typo 2001-01-25 13:13:55 +00:00
Alexey Zelkin e85c02aad1 Slightly re-word sentence to allow using .Nm macro without parameter 2001-01-25 12:11:23 +00:00
Alexey Zelkin 020a8e3a9b Slightly re-word sentence to allow using .Nm macro without parameter
Use .St macro instead of hardcoding standard name
2001-01-25 12:10:57 +00:00
Will Andrews 34bc43d532 Fix bogus checking of snprintf() by decreasing the remaining size of the
string after each successful snprintf() call.  This makes apply(1) work
*correctly*, although the whole snprintf() deal really should be redone.

Bug noted by:	nectar (about 3 weeks ago)
2001-01-25 03:40:17 +00:00
John Baldwin f5ace77533 Catch up to proc flag changes. 2001-01-24 14:28:24 +00:00
John Baldwin 0821b7ca3a Catch up to proc flag change. 2001-01-24 14:17:23 +00:00
John Baldwin ad7b044802 Catch up to new proc flags. 2001-01-24 14:03:34 +00:00
Ruslan Ermilov 1715c485d4 Mention the -F in the usage().
PR:		24586
Submitted by:	Cyrille Lefevre <clefevre@citeweb.net>
2001-01-24 08:27:59 +00:00
Jacques Vidrine 8ad2668439 Call pam_setcred.
Reviewed by:	markm, months ago
2001-01-23 21:43:32 +00:00
Hajimu UMEMOTO 5d22597f3a Add mibs to hold the number of forks since boot. New mibs are:
vm.stats.vm.v_forks
	vm.stats.vm.v_vforks
	vm.stats.vm.v_rforks
	vm.stats.vm.v_kthreads
	vm.stats.vm.v_forkpages
	vm.stats.vm.v_vforkpages
	vm.stats.vm.v_rforkpages
	vm.stats.vm.v_kthreadpages

Submitted by:	Paul Herman <pherman@frenchfries.net>
Reviewed by:	alfred
2001-01-23 14:32:01 +00:00
Peter Wemm ed1a4621a2 Add the -empty flag, from OpenBSD. It returns true if the directory
is empty.  There doesn't appear to be another easy way to do this.

mobile# mkdir foo
mobile# mkdir foo/bar
mobile# mkdir bar
mobile# find . -empty
./foo/bar
./bar
2001-01-23 11:16:50 +00:00
Dag-Erling Smørgrav 0b5c9ae2f3 Document that the -z option is equivalent to 'sysctl vm.zone'. 2001-01-23 00:37:54 +00:00
Dag-Erling Smørgrav bec62dd817 Use the vm.zone sysctl rather that grope through the zone allocator's
internal data structures.
2001-01-23 00:31:56 +00:00
Matt Jacob 97ace1c6ac Update vm zone list traversal for changes made to kernel. Note that this
is ultimately silly because no locks are held in user space while traversing
the list via kvm_reads... really, this should use the sysctl interface
which *is* protected by a lock in the kernel.
2001-01-23 00:09:30 +00:00
Will Andrews cdc8ffbbac Fix numerous style(9) bugs: Put #define's before declarations; sort the
declarations & their arguments; use only one tab after types; restore the
type of argv to sync with src tree style; sort new variables under main();
fix continuation indents; remove extra blank line before free()'s.  Still
to do: fix snprintf() handling as nectar & bde suggested to me.

Submitted by:	bde
2001-01-21 08:37:35 +00:00
Will Andrews e3cb529472 Fix style(9) bug; use ISDOT[DOT,]() macro available in util.c by moving
it to make.h so both dir.c and util.c can use it, although bde didn't
particularly like this part of the idea, IMO it's cleaner than it was.

Submitted by:	bde
2001-01-21 08:24:41 +00:00
Matt Jacob c310386321 Print out resid portion of MTIOCGET returned data. 2001-01-21 01:33:31 +00:00
Andrey A. Chernov 4eb83b01b8 Fix typo: -c -> -t 2001-01-21 01:07:26 +00:00
Andrey A. Chernov 6e1dea0642 Make "killall -t p0" really works.
Old code works only if at least one process name additionly specified.
2001-01-21 01:03:31 +00:00
Chris D. Faulhaber 8728c621a0 Check strdup() return values
Reviewed by:	kris
2001-01-20 00:26:32 +00:00
Ben Smithurst 892fc9c643 Minor grammar nit.
PR:		23742
Submitted by:	Rich Morin <rdm@cfcl.com>
2001-01-16 22:41:25 +00:00
Ruslan Ermilov 734e1e3b2e man(7) -> mdoc(7). 2001-01-16 17:04:17 +00:00
Ruslan Ermilov 9884911506 mdoc(7) police: fixed broken references. 2001-01-16 11:52:00 +00:00
David Malone 43cb2008e4 Correct spelling of millennium.
PR:		24369
Submitted by:	Tony Finch <dot@dotat.at>
2001-01-16 10:07:04 +00:00
Ruslan Ermilov 1bfea903ed Prepare for mdoc(7)NG. 2001-01-16 09:39:23 +00:00
Ruslan Ermilov 536e683425 mdoc(7) police: fix the weird construct. 2001-01-15 16:49:28 +00:00
David Malone 9f4af3be75 The patch for the new calendar contained spaces instead of tabs.
I only noticed when I went to check that it worked OK in RELENG_3.
2001-01-15 10:18:24 +00:00
Andrey A. Chernov d973f232c9 /usr/libexec/cpp -> /usr/bin/cpp
because of new rename to /usr/libexec/cpp0
2001-01-13 01:33:59 +00:00
David E. O'Brien f29126734d Have rpcgen actually tell us what cpp it is looking for (as it would if we
were SVR%).
2001-01-10 19:12:47 +00:00
David E. O'Brien 89ea5c2a49 Use /usr/bin/cpp as on NetBSD, not /usr/libexec/cpp. 2001-01-09 17:14:04 +00:00
Wolfram Schneider 47ecee5e83 Off by one error in reading mmap data.
Submitted by: Martin Kraemer <Martin.Kraemer@Fujitsu-Siemens.com>
2001-01-06 18:17:06 +00:00
Will Andrews f697348034 Reinstate revision 1.11:
BDECFLAGS; ANSIfy; use EXEC instead of "exec " where appropriate; use
proper types (size_t, int); use proper variable names for certain things;
get rid of static 'cache' style stuff by moving and sanitizing the
original SHELL checking code to main(), this also makes it easier to
free() the string; rename file-scope system() to exec_shell(); use
snprintf() everywhere instead of sprintf(); actually remember to free()
other malloc()'d char pointers in main().

I left out the -s option in this revision along with getusershell()
checking because of objections made by Warner Losh <imp> and Garrett
Wollman <wollman>.  I agreed with their assertions that such code was
unnecessary in a program like this.

I dare people to make this coredump now.

Some suggestions:	nectar (snprintf() truncate checking)
Reviewed by:		markm, eivind, jedgar
Tortured by:		examples in apply(1), fuzz(1),
			and a lot of random ideas I came up with
2001-01-05 18:15:17 +00:00
Will Andrews 9861e6df73 Back out last commit; it had string function mistakes. I will fix this
and make sure it works next time.

Submitted by:	markm, jhb
2001-01-04 20:11:09 +00:00
Will Andrews fbd7649d29 Document new -s option: pass a shell to apply(1) when the desired shell
isn't found in /etc/shells.
2001-01-04 19:28:34 +00:00
Will Andrews c494ed80cd BDECFLAGS; de-__P()-ify, ANSIfy, use snprintf() instead of sprintf(),
especially on strings passed from argv; rename system() to exec_shell(),
and make it static; use strlcpy() and make sure it works; use proper
type (size_t) to be passed to malloc()/realloc().

Use getusershell() to make sure the SHELL environment variable passed is
safe to use.  Add new option -s to allow anal users to pass things like
perl; this option is here along with getusershell() checking since the
such checking is only intended to affect things like suidperl that might
call apply(1).

Reviewed by:	markm, jhb, C. Stephen Gunn <csg@waterspout.com>
2001-01-04 19:05:49 +00:00
David Malone 2aeaf4a3fd Update for 2001.
PR:		23456
Submitted by:	jgrosch@mooseriver.com
2001-01-04 11:20:25 +00:00
Dag-Erling Smørgrav a6115eb2f8 .publickey -> .pubkey to match other finger daemons.
Suggested by:	assar
2001-01-04 10:03:44 +00:00
David Malone db3626fb72 Use a slightly better documented way of calculating easter and
include a reference to the Calendar FAQ. Also make argument parsing
a little more robust.

PR:		23881
2001-01-02 11:35:57 +00:00
Matt Jacob 23dc42d12f Oops, I'm such an idiot. For reasons I don't really agree with,
all devices are by default known by their 'cooked' name, so
my change was wrong. I thought it was a hangover from old 'block
tape device' support which hasn't worked (if it ever did) since
v6/PWB.

So, the default tape name is now the same as Linux. Far out, man....
2000-12-31 20:29:56 +00:00
Matt Jacob 95cb096e65 The default is /dev/nrsa0 (now), not /dev/nsa0. 2000-12-31 08:17:58 +00:00
Poul-Henning Kamp 1009e5708d My bad, committed the submitted patch rather than the fixed patch. 2000-12-30 21:56:18 +00:00
Poul-Henning Kamp 4d51ef6343 Use macro API to <sys/queue.h>
Submitted by:	"Jason" <jsmethers@pdq.net>
Reviewed by:	phk
2000-12-30 21:22:54 +00:00
Poul-Henning Kamp 539d2b38e2 Use macro API to <sys/queue.h>
Submitted by:	"Jason" <jsmethers@pdq.net>
Reviewed by:	phk
2000-12-30 21:17:03 +00:00
Poul-Henning Kamp baba280c68 Use macro API to <sys/queue.h>
Submitted by:	"Jason" <jsmethers@pdq.net>
Reviewed by:	/sbin/md5
2000-12-30 21:02:25 +00:00
Dag-Erling Smørgrav d17485b639 Add support for a .publickey file.
Submitted by:	Svein Skogen <tds@nsn.no>
Reviewed by:	brian, ru
2000-12-29 11:39:25 +00:00
Poul-Henning Kamp 4ea7b32b35 Used macro-API to <sys/queue.h>.
Submitted by:	ben
2000-12-29 09:27:57 +00:00
Ruslan Ermilov f4ddfb3865 Prepare for mdoc(7)NG. 2000-12-27 16:52:31 +00:00
Will Andrews 111632fd99 Fix for the case where the first two entries returned by readdir() are
actually NOT '.' and '..'.  Apparently this isn't the case when accessing
a directory via XFS over NFS on SGI systems.  Since I don't have access to
an environment like that, this will sit out in -current for at least six
weeks.  However, the patch proposed by the submitter seems acceptable, so
I've decided to commit it to the tree, in the hope that it will solve some
problems without bringing up others.

PR:		23300
Submitted by:	Jim Pirzyk <Jim.Pirzyk@disney.com>
2000-12-26 07:36:07 +00:00
Paul Saab 88522a2e3a Use the real user ID so non-root users can kill setuid processes
they started.

PR:		23356
Submitted by:	Maxim Konovalov <maxim@macomnet.ru>
2000-12-25 19:26:07 +00:00
David E. O'Brien 175f26d6ed Don't abuse the SCCS `@(#)' for RCS.
Requested by:	bde
2000-12-25 01:16:12 +00:00
David Malone 294a60d836 As far as I can tell, you have never been able to use 'ab' as a unit
name if 'a' and 'b' are unit names. You can use 'a b' though.
2000-12-24 16:15:28 +00:00
Dag-Erling Smørgrav 89a70fbeb3 Warn if the size of the remote file isn't known.
If the -R option was specified, don't truncate the local file even if its
mtime is incorrect.

PR:		bin/23719
2000-12-22 18:23:19 +00:00
Brian Somers 3b93c7437b Hostnames are case-insensitive 2000-12-22 15:21:06 +00:00
Ben Smithurst 3c6e4a5c16 Fix printf(1) for cases where a long string with no format specifiers is
followed by a %d (probably others too) format specifier.

Reviewed by:	audit
2000-12-21 22:21:38 +00:00
Brian Somers 3bebe99135 If the utmp login time is greater than the tty atime, use it to calculate
the idle time instead of the atime.

This makes entries for people that have logged in but done nothing
else show up correctly.

Reviewed by: markk@knigma.org
2000-12-21 01:30:47 +00:00
Ruslan Ermilov 9b88faecd3 Prepare for mdoc(7)NG. 2000-12-19 16:00:12 +00:00
Ruslan Ermilov c4646e2d76 mdoc(7) police: document IPv6 options in the SYNOPSIS. 2000-12-18 08:37:53 +00:00
Robert Watson 48c193e183 o Fix up includes which built due to excessive nested including in the
base system, but not in BruceBSD.
o Fix up style violations of various sorts.
o Remove redundant normalization of hertz variable, as the sysctl handler
  does this work (unlike when kread was used).

Submitted by:	bde
2000-12-17 18:43:28 +00:00
Hajimu UMEMOTO 0b5f90af27 IPv6 support for logger.
Reviewed by:	freebsd-current
2000-12-16 18:33:08 +00:00
Dag-Erling Smørgrav 65f74359cb Fix a bug introduced in rev. 1.17: initialize variables before use, not after.
Rev. 1.17 was "Obtained from NetBSD", but is significantly different from the
equivalent NetBSD revision (rev. 1.30), which does not have this bug.
2000-12-16 02:14:37 +00:00
Andrey A. Chernov e6f0df2b20 Fix lseek args order (PR 23549)
Catch and report lseek errors too
While reading header don't attempt to continue reading
if some IO operation fails

PR:		23549
2000-12-15 13:20:43 +00:00
Alexey Zelkin d2e8567ab3 Fix typo reported by Rich Morin <rdm@cfcl.com> on -doc mailing list.
Correct .Xr macro usage.
Also fix few more typos while I'm here.
2000-12-14 16:27:11 +00:00
Ruslan Ermilov 88544700ca mdoc(7) police: added missing .Os call. 2000-12-14 13:58:15 +00:00
Ruslan Ermilov ed40311694 mdoc(7) police: removed history info from the .Os FreeBSD call. 2000-12-14 11:52:05 +00:00
Ruslan Ermilov 886539482d mdoc(7) police: removed history info from the .Os call. 2000-12-14 11:40:41 +00:00
Dag-Erling Smørgrav 64638f67a7 If the URL did not specify a scheme, try to guess it from the host name. 2000-12-13 11:26:27 +00:00
John Baldwin 93480bce7c Catch up to the new kinfo_proc. 2000-12-12 23:31:44 +00:00
Ruslan Ermilov 65d9e0e006 Remove hard-sentence breaks, canonify .Dd (no leading zero). 2000-12-12 14:46:55 +00:00
Ruslan Ermilov 52e5cddf31 Document what Idle=* means in a short format display. 2000-12-12 13:37:34 +00:00
Kirk McKusick 1f7d250182 Change the proc information returned from the kernel so that it
no longer contains kernel specific data structures, but rather
only scalar values and structures that are already part of the
kernel/user interface, specifically rusage and rtprio. It no
longer contains proc, session, pcred, ucred, procsig, vmspace,
pstats, mtx, sigiolst, klist, callout, pasleep, or mdproc. If
any of these changed in size, ps, w, fstat, gcore, systat, and
top would all stop working. The new structure has over 200 bytes
of unassigned space for future values to be added, yet is nearly
100 bytes smaller per entry than the structure that it replaced.
2000-12-12 07:25:57 +00:00
Alexey Zelkin 2f3408b204 Re-add home born file(1) and magic(5) manual pages. Update them to
current file(1) version (3.33)

Approved by:	obrien
2000-12-11 15:50:04 +00:00
Ruslan Ermilov d7b336c076 mdoc(7) police: use canonical form of .Dd macro. 2000-12-11 15:47:53 +00:00
Philippe Charnier 3e7626264d Add rcsid. Remove unused #include. Remove error() definition and replace
with warn().
2000-12-10 20:54:13 +00:00
Philippe Charnier 10c959cad5 Remove one more incorrect section name. Typos.
Add rcsid. fprintf -> warn.
2000-12-10 20:52:43 +00:00
David E. O'Brien 9c8efe99eb Add history. 2000-12-10 01:10:54 +00:00
David E. O'Brien 1261f234e0 The options I added where not formated to new manpage style specs. 2000-12-09 19:03:21 +00:00
David E. O'Brien 9e50dd7726 Add or fix FreeBSD IDs. 2000-12-09 09:52:52 +00:00
David E. O'Brien a5e1cac0f5 "Implement -[n]fcb (formatting of block comments) and attempt to implement
no-space=after-sizeof (not optional) and no-space-after 'struct foo *'
(not optional).  Without these, indent unKNFizes even more perfectly KNF code."

Submitted by:	bde
2000-12-09 09:45:09 +00:00
David E. O'Brien 1a37aa566b Add `_PATH_DEVZERO'.
Use _PATH_* where where possible.
2000-12-09 09:35:55 +00:00
David E. O'Brien a3cea3dde5 Retire this ancient version of rdist. 2000-12-07 19:24:55 +00:00
David E. O'Brien a8e642f574 Change the spelling of .' to .' from .OBJDIR since `.' really is where
generated files land.  Also give precedence to generated files.
2000-12-05 22:10:43 +00:00
Alfred Perlstein 7a8671e9b7 remove struct mount from useland visibility 2000-12-04 09:21:05 +00:00
Jeroen Ruigrok van der Werven 48a1ef2284 Remove register keyword usage with prejudice.
Modern compilers are smarter when it comes to allocating register
usage.
2000-12-03 17:05:45 +00:00
Will Andrews 1a1a8c9324 There's also no point in #typedef'ing void/char pointers. Accordingly,
rip out ClientData/Address pointers and use standard types.

Obtained from:	OpenBSD
2000-12-02 20:24:42 +00:00
Jeroen Ruigrok van der Werven beed3992fc Use a size_t instead of an int. 2000-12-02 20:21:13 +00:00
Andrew Gallatin 19f085228f Correct int/long type mismatch in the proper place this time. freevnodes
and numvnodes are longs in the kernel.  They should remain longs in systat,
what really needs to change is that they should be using SYSCTL_LONG rather
than SYSCTL_INT.   I also changed wantfreevnodes to SYSCTL_LONG because I
happened to notice it.

I wish there was a way to find all of these automatically..

Pointed out by: bde
2000-12-02 20:08:33 +00:00
Jeroen Ruigrok van der Werven 247e7cb1d3 Properly constify some static arrays.
Also #if out some sccsid's and add rcsid's.
2000-12-02 19:10:12 +00:00
Will Andrews 98c28d6cc5 There's no reason to use fancy forms of NULL. Replace all instances
of NIL, NILLST, NILLGNODE, etc. with NULL.

Obtained from:		OpenBSD
2000-12-02 18:58:01 +00:00
Andrew Gallatin 36acf3d991 fix another int/long type mismatch. This one was causing pigs to
die with an fpe on alpha because fscale wasn't properly initted
2000-12-01 20:57:02 +00:00
Andrew Gallatin d468ee6f1a fix int/long type mismatches found on alpha 2000-12-01 20:01:38 +00:00
David E. O'Brien 1ab84b3fc7 Grrr... GCC 2.95.2 and 2.96 just will not agree what the default include
search paths are.  So add the requirements of both. :-(
2000-12-01 19:36:17 +00:00
David E. O'Brien 2c5569d6ff The GCC 2.96 snapshots have slightly different rules for finding include
files.  Mostly -I${.CURDIR} was needed -- especially for YACC generated
files as the new cpp does not look in the ultimate source file
(ie, the .y file)'s directory as told by the "#line" directive.  Some were
misspellings of "-I${.CURDIR}" as "-I.".
2000-12-01 09:39:28 +00:00
Robert Watson e292984cd3 o Make comment match reality, synch code with comment.
o In practice: the comment indicates that all but umask and
  environmental variables of the users login class are applied when su
  occurs, unless -m is used to specify a class.  This was incorrect;
  in practice, the uid, gids, resources, and priority were set, and
  then resources and priority were selectively removed.  This meant
  that some aspects of the user context were not set, including handling
  of login events (wtmp, utmp), as well as the path specified in
  login.conf.
o I changed it so that the behavior is the same, but instead,
  LOGIN_SETALL is used, and appropriate flags are removed, including
  the LOGIN_SETLOGIN and LOGIN_SETPATH entries that were implicitly
  not present before.  I also updated the comment to reflect
  reality, selecting reality as the "correct" behavior.
o This has the practical benefit that as new LOGIN_SET* flags are
  introduced, they are supported by su unless specifically disabled.
  For example, of a LOGIN_SETLABEL flag is introduced to support
  MAC labels determined by the user's login class, then su no longer
  has to be modified.
o It might be desirable to have su use LOGIN_SETPATH depending on
  its command line parameters, as it might or might not be
  considered part of the "environment".

Obtained from:	TrustedBSD Project
2000-11-30 23:14:55 +00:00
Will Andrews 313c36f04b Format string paranoia. This should avoid potential buffer overflows from
user input (in its ever-broadening definition).

Obtained from:	NetBSD
2000-11-30 13:56:19 +00:00
Dag-Erling Smørgrav 30204f9830 If the transfer timed out, but we don't know how large the file is supposed
to be, assume it was truncated.
2000-11-30 10:08:22 +00:00
John Baldwin 7f18d5d343 Make use of the full screen width to display p_comm rather than assuming a
hardcoded screen width of 80 chars.
2000-11-29 23:03:02 +00:00
John Baldwin 089f9b7e2f Display the name of the mutex we are blocked on in the state field. To
differentiate mutex names from wait channel names, prefix mutex names with
an asterisk.

Submitted by:	Dan Nelson <dnelson@emsphone.com>
2000-11-29 20:22:34 +00:00
Nik Clayton 71e1d8b0dd Xref make.conf(5), and point to /usr/share/doc/psd/12.make for the
tutorial paper.
2000-11-29 14:40:02 +00:00
Ruslan Ermilov ef4261bf71 Eliminate groff(1) warnings. 2000-11-29 10:56:59 +00:00
Ruslan Ermilov 38478faf72 Eliminate groff(1) warnings caused by vgrind(1). 2000-11-29 10:32:51 +00:00
Sheldon Hearn 7e812edfb7 Fix a typo and a punctuation mistake, the two of which conspired
against the reader.
2000-11-29 06:55:13 +00:00
Marcel Moolenaar 5a1ce5e6aa Add LIBCRYPT to DPADD.
Implied by: bde
2000-11-28 07:24:15 +00:00
Kris Kennaway a6f339d266 Format string auditing 2000-11-27 07:35:53 +00:00
Kris Kennaway c858db9672 *** empty log message *** 2000-11-27 06:55:38 +00:00
Kris Kennaway 40c068176d Constify 2000-11-27 06:40:35 +00:00
Kris Kennaway 50d793ebb0 Fix format string warnings.
Submitted by:	nra
Obtained from:	NetBSD
2000-11-27 04:26:39 +00:00
Kris Kennaway 56e7ae90cb Cleanup this code a bit by attempting to sync it up with NetBSD and
with each other.

Reviewed by:	markm, dwmalone
2000-11-26 22:36:35 +00:00
David E. O'Brien 5576244cd6 Use the vendor's manpages (which are in old -man format) rather than
our modified one based on a much older version of the vendor's manpage.
2000-11-26 22:19:56 +00:00
Kris Kennaway f6fd83ed27 Correct definition of MAXHOSTNAMELEN in ifdef'ed code.
Submitted by:	Edwin Groothuis <mavetju@chello.nl>
PR:		bin/22787
2000-11-26 21:37:51 +00:00
Kris Kennaway cca0db7e7e Constify 2000-11-26 11:07:45 +00:00
Kris Kennaway da4cd46eac vsprintf() -> vsnprintf() 2000-11-26 08:14:55 +00:00
Robert Watson c3a2720353 o Make systat/vmstat.c use sysctl() to retrieve cp_time, bufspace,
maxvnodes, numvnodes, freevnodes, nchstats, and numdirtybuffers.
o Make the hw.ncpu error checking code a little more rigorous by
  sanity checking the returned data size.
o Didn't fix machine-dependent non-sysctl-exported variables:
  intrnames, eintrnames, intrcnt, eintrcnt, as these variables are
  defined and exported from machine-dependent kernel code in
  assembly.  This should probably be fixed somehow.
2000-11-25 03:53:42 +00:00
Robert Watson 00df22775a o make systat/pigs.c use syctl() to retrieve cp_time, fscale, and ccpu
instead of using kmem.
2000-11-25 03:49:42 +00:00
Robert Watson 8c82fe65a7 o Make systat/iostat.c use sysctl() to retrieve cp_time instead of
kmem.
2000-11-25 03:47:36 +00:00
Robert Watson 7ace4e618a o Make systat use sysctl() to retrieve hz and stathz, instead of
using kmem.
2000-11-25 03:46:45 +00:00
Ruslan Ermilov 92ee29d2a5 Reimplement the groff(1) warnings elimination fixes in a better way. 2000-11-24 10:05:30 +00:00
Joseph Koshy b67f439c91 [rsh.1] Document the -4' and -6' options.
[rsh.c] Make usage message match the code.
2000-11-24 09:25:44 +00:00
Joseph Koshy 0deea1c066 [rlogin.1] Document the -4' and -6' options. Correct a typo.
[rlogin.c] Make the usage message match the code.
2000-11-24 09:14:09 +00:00
Ruslan Ermilov bbc7e5700d Eliminate groff(1) warnings. 2000-11-23 15:21:30 +00:00
Ben Smithurst d9a7d86c29 kenv(1) first appeared in FreeBSD 4.1.1, not FreeBSD 5.0.
PR:		23020
Submitted by:	Simon Dick <simond@irrelevant.org>
2000-11-23 11:21:35 +00:00
Alexey Zelkin 89368610f8 Use correct macro for path name
PR:		docs/13218
2000-11-22 17:53:17 +00:00
Kris Kennaway 4f377e65c4 Create temporary files in a secure directory, instead of using multiple
filenames based on a single invocation of mktemp() in /tmp, which is
easily predictable after the first one.

Audited by:     markm
2000-11-22 11:09:30 +00:00
Ruslan Ermilov f4d874a1db mdoc(7) police: do not split author names in the AUTHORS section. 2000-11-22 09:35:58 +00:00
Ruslan Ermilov 8fe908ef0c mdoc(7) police: use the new features of the Nm macro. 2000-11-20 19:21:22 +00:00
Ruslan Ermilov 3450dff7f1 mdoc(7) police: use the new features of the Nm macro. 2000-11-20 12:18:54 +00:00
Marcel Moolenaar c71b3c67f1 Add -lcrypt. This fixes cross-building. 2000-11-20 02:19:05 +00:00
Kris Kennaway 29ac114aae Unlink the temporary file immediately so it is removed on exit.
Obtained from:	OpenBSD
2000-11-19 12:04:12 +00:00
Kris Kennaway f743d11975 Fix a buffer overflow from a long local hostname.
Obtained from:	OpenBSD
2000-11-19 10:08:26 +00:00
John W. De Boskey aecbd99950 Add/fix the ability to split a file larger than 2 gigabytes.
Added $FreeBSD tag (in the way the already present sccsid is
done). I've been told the rcsid stuff may be of dubious value
so I'm curious to know if folks (still) use it.

Submitted by:	Brad Chisholm <blc@bsdwins.com>
2000-11-19 01:44:20 +00:00