Commit Graph

15300 Commits

Author SHA1 Message Date
Dag-Erling Smørgrav
36d67475f5 xinstall: fix dounpriv logic, add tests
Sponsored by:	Klara, Inc.
MFC after:	1 week
2022-08-03 21:03:49 +02:00
Tom Jones
190c4c2499 diff3: Use ranges for new and old diffedits in ed scripts
This should make the output logic easier to read. No functional change
intended.

Sponsored by:	Klara, Inc.
2022-08-02 14:38:11 +01:00
Tom Jones
c0e6ccb12a diff3: Use ranges for the old and new diffedits in A scripts
This makes the output logic easier to read. No functional change
intended.

Sponsored by:	Klara, Inc.
2022-08-02 14:37:05 +01:00
Tom Jones
264a559ac8 diff3: Simplify startmark calculation in Ascript
Remove redundant calculation for startmark.

Sponsored by:	Klara, Inc.
2022-08-02 14:36:05 +01:00
Gordon Bergling
93b8510c36 find.1: Correct the markup
- ASCII is an acronym and there is no ascii(8) manual page
- Reference ascii(7) in the SEE ALSO section

Reported by:	karels
X-MFC with:	321dc6ee7e
2022-08-02 08:33:20 +02:00
Tom Jones
2c4276aaa2 diff3: Use variables for old and new in A scripts
This makes the code easier to follow, no functional changes intended

Sponsored by:	Klara, Inc.
2022-08-01 14:54:20 +01:00
Tom Jones
ca53a8445a diff3: Replace literal marker with variable
Sponsored by:	Klara, Inc.
2022-08-01 14:53:53 +01:00
Tom Jones
85d92faf43 diff3: Fix indentation
Sponsored by:	Klara, Inc.
2022-08-01 14:14:25 +01:00
Xin LI
0404b8c88f Deprecate minigzip(1) in preparation of removing it from base system.
Reviewed by:	emaste, pauamma
MFC after:	2 weeks
Differential Revision: https://reviews.freebsd.org/D36000
2022-07-31 15:16:22 -07:00
Gordon Bergling
321dc6ee7e find.1: Fix mandoc warnings and mention a useful manpage
- new sentence, new line
- unknown AT&T UNIX version: At v7
- no blank before trailing delimiter
- reference the ASCII(8) manual page

MFC after:	5 days
2022-07-31 16:38:10 +02:00
Stefan Eßer
dc9e68ad01 calendar: clarify comment syntax in man page
The single line comment indicator '//' is only detected at the
beginning of a line or when following white space to allow URLs
in calendar entries.

MFC after:	3 days
2022-07-31 07:37:05 +02:00
Doug Rabson
0c19c4db74 Move sort to runtime
Allows pkg bootstrap without having to install FreeBSD-utilities
2022-07-29 11:27:25 +01:00
Warner Losh
6feb6b4ffc ncal: LT is the country code for Lithuania
PR: 265479
MFC After: 3 days
2022-07-28 11:35:50 -06:00
Simon J. Gerraty
532d4fbfa0 Update to bmake-20220726
Merge commit '31a96ca5f0b6e5f8f7fa8cecf3a5c4354b3b096f'
2022-07-27 09:00:30 -07:00
Simon J. Gerraty
08604a023d Auto-create bmake/unit-tests objdir if appropriate
Given the way bmake/unit-tests is visited, when doing 'test'
MK_AUTO_OBJ=yes will not be effective.
So create the objdir before running the sub-make.

Also ensure MAKEOBJDIR is passed to opt-m-include-dir

Reviewed by: deo
2022-07-26 13:24:34 -07:00
Simon J. Gerraty
58cd36950c Finish update to bmake-20220724 2022-07-26 11:06:27 -07:00
Warner Losh
8a02ea1dbc nl: Correct history
nl actually first was available with System III, not System Vr2. Updated
based on discussion on TUHS mailing list (archive recently moved so this
message isn't get available in the archive).

Suggested by: segalogo (Matt G)
2022-07-24 15:01:52 -06:00
Eugene Grosbein
d6054ee652 find.1: small language fix after previous change
collate -> collation
2022-07-22 18:46:38 +07:00
Eugene Grosbein
26a329f49f find.1: explain why "find -s" may differ from "find | sort"
In short, that's because a directory name may end
with a character that goes before slash (/).

MFC after:	1 week
2022-07-22 18:39:47 +07:00
Ed Maste
119db52f42 vtfontcvt: improve hex font format validation
Previously an EOF would result in sscanf returning -1 leading to a
crash.

MFC after:	1 week
Sponsored by:	The FreeBSD Foundation
2022-07-19 11:48:09 -04:00
Mateusz Piotrowski
f4b00609ec backlight(8): Update usage() to match the manual page
MFC after:	1 week
2022-07-19 16:56:27 +02:00
Mateusz Piotrowski
64a231b90b backlight.8: Show all possible modes in synopsis
MFC after:	1 week
2022-07-19 16:55:25 +02:00
Mateusz Piotrowski
5c3e424958 backlight.8: Standardize synopsis and improve examples
MFC after:	1 week
2022-07-19 16:49:50 +02:00
Mateusz Piotrowski
ef2d0816dd vtfontcvt(8): Update usage() to match vtfontcvt.8
MFC after:	2 weeks
2022-07-19 16:35:50 +02:00
Mateusz Piotrowski
cad64622ca vtfontcvt.8: Use D1 instead of Ql for readability
MFC after:	2 weeks
2022-07-19 16:35:49 +02:00
Mateusz Piotrowski
e0bd2ab2eb vtfontcvt.8: Sort synopsis
MFC after:	2 weeks
2022-07-19 16:35:49 +02:00
Mateusz Piotrowski
b38e3722f5 vtfontcvt.8: Improve synopsis and -f documentation
MFC after:	2 weeks
2022-07-19 16:35:48 +02:00
Ed Maste
df777aeb98 vtfontcvt: correct usage
Commit e7fd9688ea changed vtfontcvt's command line parsing, but did
not correctly update the usage (it omitted the new -o flag).

Fixes:		e7fd9688ea ("Move font related data structured to...")
MFC after:	1 week
Sponsored by:	The FreeBSD Foundation
2022-07-18 13:24:29 -04:00
Xin LI
1fbfa7a8dc usr.bin/cksum: localize _total variables. 2022-07-17 17:24:31 -07:00
Dmitry Chagin
ae37e4a0d1 kdump(1): Sort options in alphabetical order.
Reviewed by:		imp (early rev)
Differential Revision:	https://reviews.freebsd.org/D35775
MFC after:		2 weeks
2022-07-16 12:47:54 +03:00
Dmitry Chagin
fc90f3a281 ktrace: Increase precision of timestamps.
Replace struct timeval in header with struct timespec.
To differentiate header formats, add a new KTR_VERSIONED flag
set in the header type field similar to the existing KTRDROP flag.

To make it easier to extend ktrace headers in the future,
extend the existing header with a version field (version 0 is
reserved for older records without KTR_VERSIONED) as well as
new fields holding the thread ID and CPU ID.

Reviewed by:		jhb, pauamma
Differential Revision:	https://reviews.freebsd.org/D35774
MFC after:		2 weeks
2022-07-16 12:46:12 +03:00
John Baldwin
a6c3e5fa39 gcore: Trim stale bits from elf32core.c.
These should have been removed in
d95657a1a7.

Reviewed by:	markj
Sponsored by:	DARPA
Differential Revision:	https://reviews.freebsd.org/D35748
2022-07-14 13:03:34 -07:00
Xin LI
643ac419fa Improve usability of head(1) and tail(1):
- Consistently support -q (quiet) and -v (verbose)
 - Allow specifying numbers with SI prefixes supported by expand_number(3)
 - Remove 2^31 limit on lines for head(1)

MFC after:		2 weeks
Reviewed by:		lwhsu, pauamma, gbe
Relnotes:		yes
Differential Revision: https://reviews.freebsd.org/D35720
2022-07-12 21:14:25 -07:00
Mateusz Piotrowski
6452fb1e87 protect.1: Document that protect(1) does not work in jails
The reason is that in order to protect a process procctl(2) needs
the PRIV_VM_MADV_PROTECT privilege, which is currently denied in jails
(see kern_jail.c).

MFC after:	1 week
2022-07-12 00:47:58 +02:00
Mateusz Piotrowski
cb56f86025 protect.1: Improve synopsis
While here, make the list's -width argument a bit shorter for
readability.

MFC after:	3 days
2022-07-07 20:09:16 +02:00
Gleb Smirnoff
d961ccd350 sockstat(1): print PID adjusted to the right
This allows for easy copy-and-paste of a unix(4) peer name for lookup.
With current implementation it is guaranteed that a peer listed could be
found in the output.

Differential revision:	https://reviews.freebsd.org/D35727
2022-07-06 22:19:08 -07:00
Gleb Smirnoff
2c436d4890 sockstat(1): print out full connection graph for unix(4) sockets
Kernel provides us with enough information to display all possible
connections between UNIX sockets.

o Store unp_conn, xu_firstref and xu_nextref in the faddr of a UNIX sock.
o Build tree of file descriptors, indexed by the socket pointer.
o In displaysock() print out all possible information:
  1) if socket is bound, print name of this socket
  2) if socket has connected to a peer with a name, print peers name
  3) if socket has connected to a peer without a name, print [pid fd]
  4) if a bound socket has received connections, print list of them
     as [pid fd]
  Previously, only 1) either 2) were printed.

Reviewed by:		tuexen
Differential revision:	https://reviews.freebsd.org/D35726
2022-07-06 22:19:08 -07:00
Gleb Smirnoff
c5bdcd1f10 sockstat(1): widen the FD printing format
Three digit file descriptors are very common these days.  So let the
columns not break with them.

Reviewed by:		tuexen
Differential revision:	https://reviews.freebsd.org/D35725
2022-07-06 22:19:08 -07:00
Gleb Smirnoff
a83d596f43 sockstat(1): use tree(3) rbtree instead of hash
o Use tree to lookup by socket kvaddr. The size of hash is too big for a
  small virtual machine and at the same time too little for a large
  production server.  A tree would better fit here.
o For those pcbs, that don't have a socket associated, use a list.
o Provide a second tree to lookup by pcb kvaddr.  These removes full hash
  traversal when printing every unix(4) socket.

Reviewed by:		tuexen
Differential revision:	https://reviews.freebsd.org/D35724
2022-07-06 22:19:08 -07:00
Gleb Smirnoff
7d016011f4 sockstat(1): we don't need kernel struct unpcb
Fixes:	0e229f343f
2022-07-06 22:19:08 -07:00
Mike Karels
231092bb6f netstat -i: do not truncate interface names
The field for interface names for netstat -i was 5 characters by
default, which is no longer sufficient with names like "vlan1234"
and "vtnet0".  netstat -iW computed the necessary field width, but
also enlarged the address field by a lot (especially with IPv6 enabled).
Make netstat -i compute the field width for interface names with or
without -W.  Note that the existing default output does not fit in
80 columns in any case.  Update the man page accordingly, documenting
the remaining effect of -W with -i.  Also add -W to the list of
General Options, as there are numerous pointers to this.

Reported by:	Chris Ross
Reviewed by:	melifaro, rgrimes, cy
Differential Revision: https://reviews.freebsd.org/D35703
MFC after:	1 week
2022-07-06 07:12:16 -05:00
Tom Jones
1e692b938e xargs: fix description of strnsubst return value
Reported by:	oshogbo
Sponsored by:	Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D35574
2022-07-05 16:27:15 +01:00
Tom Jones
f058359ba5 xargs: terminate if line replacement cannot be constructed
If the line with replacement cannot be constructed xargs should
terminate as documented in the man page

We encounter this error, but gnu/xargs doesn't because they have a much
larger limit for created outputs (~10000 lines).

Reviewed by:	oshogbo
Sponsored by:	Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D35574
2022-07-05 16:18:05 +01:00
Tom Jones
d458eb8de1 diff3: make the eflag logic easier to follow
Discussed with:	dim
Sponsored by:	Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D35324
2022-07-05 12:36:11 +01:00
John Baldwin
d95657a1a7 gcore: Use PT_GETREGSET for NT_THRMISC and NT_PTLWPINFO.
This avoids the need for dealing with converting lwpinfo for alternate
ABIs in gcore itself.

Reviewed by:	markj
MFC after:	2 weeks
Sponsored by:	DARPA
Differential Revision:	https://reviews.freebsd.org/D35667
2022-06-30 10:05:02 -07:00
John Baldwin
d2a3c30a51 gcore: Remove unused typedefs.
These are no longer needed after commit 4965ac059d which used
PT_GETREGSET to fetch NT_PRSTATUS and NT_FPREGSET.

Reviewed by:	markj, emaste
MFC after:	2 weeks
Sponsored by:	DARPA
Differential Revision:	https://reviews.freebsd.org/D35665
2022-06-30 10:04:49 -07:00
Fernando Apesteguía
4a3c598f35 Bump .Dd for recently modified manual pages
During the removal of named(8) references, some pages were modified but their
.Dd where not updated accordingly.

Reported by:	lwhsu@
Fixes:	942e234d86
2022-06-27 18:20:03 +02:00
Fernando Apesteguía
942e234d86 Remove references to named(8)
named(8) hasn't been in base for some time. Remove all references to it in
manual pages.

Approved by:	manpages (Pau Amma)
Differential Revision:	https://reviews.freebsd.org/D35586
2022-06-26 18:53:08 +02:00
Tom Jones
26b5deef22 diff3: Add man page description for version and help
Reviewed by:	Pau Amma
Sponsored by:	Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D35325
2022-06-23 13:37:28 +01:00
Alexander V. Chernikov
c8f34118ac netstat: print path weight when showing routes in structured output.
Differential Revision: https://reviews.freebsd.org/D35530
MFC after:	2 weeks
2022-06-22 12:47:06 +00:00