Commit Graph

8255 Commits

Author SHA1 Message Date
laszlof
b71f6de416 Add my birthdate to the calendar.
Approved by:	flz (mentor)
2006-11-07 14:35:34 +00:00
bde
95c27ab845 Second stage of unbreaking thr formatting of the NICE field: decode the
priority class and use this to:

- print "-" instead of a garbage value for ithreads.  Print "-" instead
  of the unused nice value for kthreads which are (mis)classified as
  PRI_TIMESHARE.  For such threads, the nice value can be set to nonzero
  by root, but it is never used (at least by the 4bsd scheduler).  For
  ithreads, we didn't even print the unused value.

- print "i<priority>" and "r<priority>" instead of a biased "<priority>"
  for idletime and realtime threads,  Here <priority> is the priority
  parameter to idprio/rtprio(1).  Just add the prefix and remove the
  bias for now.  <priority> has been stored indirectly in the kernel
  since 2001/02/12, and even the kernel cannot recover the original
  value in all cases.  Here we need to handle more cases than pri_to_rtp(),
  but actually handle fewer cases, and end up printing garbage after
  a thread changes its current priority while in the kernel.

- for idletime and realtime threads, if they are kthreads then add a prefix
  of "k" to the previous string.

- for idletime and realtime threads, if they in the FIFO scheduling class
  then add a suffix of "F" to the previous string (if it fits; the other
  parts of the string are sure to fit unless <priority> is garbage).
2006-11-07 10:03:10 +00:00
dds
771f010d42 Style facelift.
- Reduce the number of global variables
- Make global objects static
- Use bool consistently
- Sort getopt arguments and their processing
- Add function comments
- Change notlast != 0 into !last
2006-11-06 15:58:35 +00:00
trhodes
34663c9485 Add needed hyphens, note the KTRACE kernel option, bump doc date.
PR:		85186
Submitted by:	garys
2006-11-06 15:17:50 +00:00
dds
41f3c2053f Use a more sensible default of 1 or -1 when only the start and
end values are specified.

PR:		bin/68981
Submitted by:	Stefan `Sec` Zehl
MFC after:	2 weeks
2006-11-06 15:11:50 +00:00
dds
c15edb9d96 Do What I Mean when the user asks for random integers or characters.
Up to now jot would fail to generate the last character in the range
or skew the integer distribution in a way that would generate the numbers
in the range's limits with half the probability of the rest.

This modification fixes the program, rather than documenting the
strange behavior, as suggested in docs/54879.

Also, correctly specify the range of random(3).

PR:		docs/54879
MFC after:	2 weeks
2006-11-06 13:55:11 +00:00
dds
571eb96dc6 Avoid negative array indices: an empty string can also be used
to specify a default value.
2006-11-06 11:03:43 +00:00
dds
dc4421d112 See also arc4random
PR:		docs/54879
MFC after:	2 weeks
2006-11-06 10:39:49 +00:00
dds
f4df3d376b Restore jot's ability to use a seed for producing a deterministic
sequence of random numbers.
This functionality was lost in revision 1.9 when the random number
generator was switched to arc4random.

PR:		docs/54879
MFC after:	2 weeks
2006-11-06 10:30:29 +00:00
dds
e9549fc276 Replace obscure aliases through pointers with plain variables.
MFC after:	2 weeks
2006-11-06 09:15:21 +00:00
dds
4b2e1ee229 Merge code in common cases.
Verified by:	New regression tests in tools/regression/usr.bin/jot
MFC after:	2 weeks
2006-11-06 08:47:41 +00:00
dds
d2eb59a85e Replace opaque numeric bit flag values with #defined identifiers.
While there, add some missing FALLTHROUGH comments.

Verified with:	cmp(1) on the executable
MFC after:	2 weeks
2006-11-06 07:26:16 +00:00
rwatson
a2444d132b Cross-reference libmemstat(3), malloc(9), uma(9). 2006-11-02 19:53:57 +00:00
kientzle
2f99905b1f Fix "1 day ago", "yesterday" and similar relative-time phrases
when parsing dates.

PR: bin/104934: bug in some date handling of bsdtar
Reported by: Herve Boulouis
MFC after: 3 days
2006-11-02 04:16:15 +00:00
ru
9ee8843099 Fix a bug converting a variable from the numeric type to a string.
PR:		bin/104795
MFC after:	3 days
2006-10-25 21:23:20 +00:00
ru
956fcf47f7 Document the NM environment variable. 2006-10-25 09:40:07 +00:00
grog
de0a74e023 Bizet was only born once. 2006-10-24 23:18:07 +00:00
sobomax
19094a2bf3 Backout previous change (SIGSYS related). The fix has been applied to the
proper place.

Pointed out by:	rwatson
2006-10-24 17:41:28 +00:00
sobomax
1d06416b30 Ignore SIGSYS when BSM is compiled in. Otherwise, attempt to invoke su on
system that don't have audit framefork compiled into kernel or ia32 binary
on amd64 system will result in SIGSYS. There is one place in su.c itself
where it tries to check for errno != ENOSYS, but it has been a nop since su
does not catch SIGSYS anyway. There are few other places in libbsm,
where attempt to invoke audit syscal would result in SIGSYS if no audit
support is present in the kernel, so that the only reliable method for
now is to disable SIGSYS completely in the case when BSM is compiled in.

In the long run, both direct invocation of audit-related syscalls and
libbsm should be made more intellegent to handle the case when BSM is not
compiled into the kernel gracefully.

MFC after: 3 days
           (provided re@ approval)
2006-10-24 08:18:10 +00:00
ru
28e979171a - Document the default disk block usage unit.
- Add option -h, human-readable output.

PR:		docs/53732
2006-10-21 23:57:38 +00:00
marcel
0e4a74aceb Better handle the -F case:
o  When stat(2) fails (i.e. the file has been moved) there's no new
   file with the same name yet, so keep showing the file that's open.
   This yields the same behaviour as -f, for which we don't stat(2).
o  When a new file with the same name has been created (i.e stat(2)
   succeeds but the inode or device numbers differ from the opened
   file), show any new lines in the opened file (i.e. the old or
   rotated file) before reopening the new file.

These changes fix the observed behaviour that tail(1) doesn't show
the very last lines of the rotated (log) files.

PR: bin/101979
Tested by: Jos Backus <jos@catnook.com>
MFC after: 2 months
2006-10-21 18:05:06 +00:00
ru
95ec5519d6 The vm.zone sysctl has gone; zone stats are now supplied by libmemstat(3). 2006-10-21 10:40:12 +00:00
ru
7b0d9d9885 - Add comma after REQUESTS field missed in previous commit.
- Widen some columns; make width of header columns less cryptic.
2006-10-21 10:16:26 +00:00
glebius
8f073c1e71 Print the number of allocation failures in UMA zones.
PR:	kern/102940
2006-10-21 09:08:35 +00:00
cperciva
731fe330c9 Document that jot(1), rs(1), and lam(1) first appeared in 4.2BSD.
MFC after:	1 month
2006-10-20 04:31:01 +00:00
ru
c8e1d7d89e Document that unexpand(1)'s -a and -t options are exclusive.
PR:		docs/85063
2006-10-13 16:22:25 +00:00
ru
aeb789985a - Document all character classes our tr(1) supports. [1]
- Mention that some of them are POSIX extensions.  [2]

PR:		docs/85062 [1]
Submitted by:	Toby Peterson [1]
Obtained from:	wctype(3) [2]
MFC after:	3 days
2006-10-13 16:13:45 +00:00
ru
0639569dc1 At least one argument is required. 2006-10-12 21:10:55 +00:00
ceri
acf3467264 Saint George replaced Saint Edward as the patron Saint of England
somewhere around 1348.

The revision log doesn't seem to go back quite that far, but I assume
that the update to this file was forgotten in the celebrations.

While, here, note which countries the other UK patron Saints hold
patronage of.

Sources include http://www.novareinna.com/festive/georgeday.html and
http://www.newadvent.org/cathen/
2006-10-12 11:08:29 +00:00
ru
2e612fd703 Memory utilization subscreen in "vmstat" display lists numbers in KB,
not in number of pages.

PR:		docs/71690
Submitted by:	Jan Srzednicki

(A patch is only partially merged, the rest was already fixed by bde@
in rev. 1.51.)
2006-10-12 10:54:34 +00:00
ru
36b138121c Don't go beyond the provided string when parsing the `\' character.
PR:		bin/99985
Submitted by:	Nate Eldredge
MFC after:	3 days
2006-10-09 19:37:26 +00:00
ceri
d0efcf3aa7 Update the list of POSIX extensions.
PR:		docs/103859
Submitted by:	shaun
MFC after:	1 week
2006-10-08 10:31:44 +00:00
flz
1101c26eb3 Add a missing new line at the end of the australian calendar file to
suppress and error message.

PR:		conf/99490
Submitted by:	Shaun Branden <shaun@pcuse.com>
Approved by:	cperciva (mentor)
MFC after:	1 day
Sponsored by:	FreeBSD Test-Bugathon
2006-10-06 23:20:01 +00:00
xride
4ed2930c61 Adding my birthday
Approved by:	tmclaugh
2006-10-01 16:17:10 +00:00
maxim
5e72f6a094 o Remove an obsoleted (and commented out) entry.
PR:		conf/85143
Submitted by:	Helge Oldach
2006-10-01 09:22:05 +00:00
maxim
be75d21a91 o Strip eol w/spaces. 2006-10-01 06:30:51 +00:00
maxim
ed9b2ef9bc o Add a Gedenktag.
PR:		conf/85143
Submitted by:	Helge Oldach
MFC after:	1 weeks
2006-10-01 06:29:35 +00:00
ru
7b594fc556 Revise markup. 2006-09-30 17:27:50 +00:00
ru
31c9074bac Markup nit. 2006-09-29 21:17:10 +00:00
bms
b7f17de1eb Nits.
Submitted by:	ru
2006-09-29 16:16:41 +00:00
bms
686e54733a Push removal of mrouted down to the rest of the tree. 2006-09-29 15:45:11 +00:00
ru
33e34aeeb5 Markup fixes. 2006-09-29 15:20:48 +00:00
luoqi
16c630b2da Do not chdir(2) until after setuid(2), otherwise "su - username" would fail
when root doesn't have the permission to enter target user's home directory.
If set, PAM environment variable HOME will be used in chdir(2) instead of
pwd->pw_dir, this allows pam_chroot module to continue to function.
2006-09-29 04:41:37 +00:00
matteo
945cd1291e Set txrx_error to 1 when we reach abort. This makes the program correctly set the exit code.
The PR has further details on this.

PR:		bin/103206
Submitted by:	John Hickey <jjh-freebsd@daedalian.us>
MFC after:	3 days
2006-09-28 21:22:21 +00:00
stas
88c514ae0f - Add my birthday entry to the chronicle.
Approved by:	sem (mentor)
2006-09-27 08:25:53 +00:00
ceri
f4747864d3 Add a -a option as a no-op for Solaris compatibility, as briefly
discussed on src-committers.  This is intentionally not included in the
usage() function as it would confuse the output too much.

Approved by:	jhb
MFC after:	1 week
2006-09-26 22:28:12 +00:00
ru
2b7fa83213 Fix both arguments to err(). 2006-09-26 05:46:55 +00:00
marck
d5034d7375 Fix bug introduced in rev 1.23:
pw_equal does not check crypted password field, so one cannot change
crypted password keeping other fields intact.

Approved by:	des
MCF after:	3 days
2006-09-25 15:06:24 +00:00
rwatson
2f0a02201d Rename "-a" flag to "-A" in order to avoid conflicting with the "-a" flag
as found on Solaris.

Requested by:	ceri
MFC after:	3 days
2006-09-23 15:43:29 +00:00
rwatson
fae2ccfa41 Add a -a argument to id(1), which causes id(1) to print out process
audit properties, including the audit user id.  This can be quite
helpful in debugging audit problems.

Obtained from:	TrustedBSD Project
MFC after:	3 days
2006-09-23 12:30:31 +00:00