Make script(1) a little less broken.
Close the file descriptor to the TTY. There is no reason why the parent
process should keep track of the descriptor. This ensures that the
application inside properly drains the TTY during exit(2).
Reported by: alfred
Teach procstat(1) to display some information about signal disposition
and pending/blocked status for signals.
MFC r204880:
Add file forgotten in r204879.
The -newerXB option was being interpreted the same as the -newerXm option
as a check for F_TIME2_B was missing. Fix this.
PR: bin/138245
Submitted by: "David E. Cross" <crossd cs.rpi.edu>
The correct value of DEL is 0x7f, not 0xff. This is purely a documentation
issue - od(1) and hexdump(1) behave as expected.
PR: docs/143869
Submitted by: gcooper
- Cast intptr_t, pid_t and time_t values to intmax_t and use %jd with
printf.
- Cast the system call return value to long and use %ld in a printf in
ktrsysret().
PR: bin/123774
Initialize the execfile argument to NULL instead of _PATH_DEVNULL. This allows
the -M option to be used without specifying -N.
PR: bin/138146
Approved by: rrs (mentor)
Add a new option, -q howmany, which when used in conjuction with -w,
exits netstat after _howmany_ outputs.
Requested by: thomasa
Reviewed by: freebsd-net (bms, old version in early 2007)
Remove non-working special case for pipe(2) from amd64-fbsd32.c and
i386-fbsd.c. Add pipe(2) to syscall table to decode it's pointer
argument properly and re-add special handling for pipe(2) return value
to print_syscall_ret().
PR: bin/120870
Add fork(2), getegid(2), geteuid(2), getgid(2), getpid(2), getpgid(2),
getpgrp(2), getppid(2), getsid(2) and getuid(2) to syscall table to
decode their arguments correctly.
MFC r201512:
Modernize scandir(3) and alphasort(3) interfaces according to the IEEE
Std 1003.1-2008.
MFC r201602:
Move scandir(3) and alphasort(3) into XSI namespace.
MFC r201604:
Use thunks to adapt alphasort-like interface to the comparision function
required by qsort() and qsort_r().
MFC r202556 (by ache):
Use strcoll() in opendir() and alphasort(). Remove some comments.
MFC r202572 (by ache):
Revert to using strcmp() for opendir().
MFC r202677 (by ache):
Style.
MFC r202679 (by ache):
Style: rename internal function to opendir_compar().
MFC r202691 (by ache):
For alphasort(3) add reference to strcoll(3).
MFC r202693 (by ache):
Style: reword comment.
The devices that supported EVFILT_NETDEV kqueue filters were removed in
r195175. Remove all definitions, documentation, and usage.
The change of function signature for vlan_link_state() was not merged to
maintain the ABI.
- Remove -d option, whois.nic.mil doesn't exist anymore.
- Make whois capable of searching for IPv6 addresses just like it can
do for IPv4 addresses without having to explicetly specify that the
ARIN server should be used to get the initial information.
PR: bin/142507, bin/128725
Submitted by: Dan Mahoney <danm@prime.gushi.org>, "Matt D. Harris" <mdh_lists@yahoo.com>
Fix return code in the case of successful file transfer, broken in
tftp.c 1.13
PR: bin/117452
Submitted by: Spencer Minear minear securecomputing.com
Approved by: ed (mentor, implicit)
Change gcore in order to get rid of the procfs support and use FreeBSD's
specific interfaces. Main changes:
- now gcore recognizes threads within the the process and handle dumps on
a thread scope
- the process to be analyzed should be stopped while gcore runs
- gcore may not work with processes that are being debugged with gdb or
truss
- ptrace may let interruptible calls to return EINTR, thus dirtying
signals handling within the process
Sponsored by: Sandvine Incorporated
Add the possibility to show informations about dropped packets on the
input path when showing interfaces informations.
Sponsored by: Sandvine Incorporated
Add more statistics variables for IPcomp.
Try to version the struct in a backward compatible way.
People asked for the versioning of the stats structs in general before.
Note: old netstat binaries, as only consumer, continue to work as they are
still using kvm but will not display the new stats. [1]
Discussed with: rwatson [1]
- Catch SIGHUP to perform cleanup before exiting.
- Exit if getch() returns with an error other than EINTR. Otherwise
systat(1) may get stuck in an infinite loop if it doesn't receive
SIGHUP when terminal closes.
- Remove attempt to clear stdio error indicators. getch() doesn't use
stdio, making it useless.
- Remove unneeded masking of getch() return value.
PR: bin/107171
Approved by: trasz (mentor)
Modified locale(1) to be able to show the altmon_X fields and the
[cxX]_fmt's. Also modify the "-k list" option to display only
fields with a certain prefix.
Add the comment "(FreeBSD only)" to the altmonth_x keywords
It is a bit unfortunate that the example to delete broken symlinks now uses
rm(1), but allowing this with -delete would require fixing fts(3) to not
imply FTS_NOCHDIR if FTS_LOGICAL is given (or hacks in the -delete option).
PR: bin/90687
Print routing statistics as unsigned short rather than unsigned int,
otherwise sign extension leads to unlikely values when in the negative
range of the signed short structure fields that hold the statistics.
The type used to hold routing statistics is arguably also incorrect.
Approved by: re (bz)
was harmless prior to r195693, when mmap(2) changed from silently ignoring
requests for mapping zero bytes to returning EINVAL; this commit can be seen
as adjusting for the change in mmap(2) in order to make look(1) act like it
did previously.
Reviewed by: jhb
Approved by: re (kib)
This affects only fstat on zfs and devfs, only on 64-bit systems
and only when fsid is greater than 2^31 - 1.
When fstat examines a file via stat(2) it takes uint32_t st_dev
and assigns to (signed) (64-bit) long fsid, this results in
a positive value.
When fstat examines opened files it takes int32_t f_fsid.val[0]
and assigns to (signed) (64-bit) long fsid, this results in
a negative value.
So, while initially st_dev and f_fsid.val[0] have the same bit
values they get promoted to different 64-bit values because
of the signed-vs-unsigned difference.
A fix is to use "more natural" positive numbers by introducing
intermediate unsigned cast for f_fsid.val[0].
Reviewed by: jhb, lulf
Approved by: re (kib)
MFC after: 1 week (to stable/7)
- Limit suffix to be no more than 30 bytes long. This matches GNU
behavior.
- Correct usage of memcpy().
Note that this commit only corrects the stack underflow issue, we
still need some other fixes to cover other edges. [1]
Reported by: Ron Jude <ronj wytheville org>
Discussed with: Matthew Green (original NetBSD gzip author),
Eygene Ryabinkin <rea-fbsd codelabs ru> [1]
Approved by: re (kib)
Major changes from v429:
* Don't pass "-" to non-pipe LESSOPEN unless it starts with "-".
* Allow a fraction as the argument to the -# (--shift) option.
* Fix highlight bug when underlined/overstruck text matches at end of line.
* Fix non-regex searches with ctrl-R.
Approved by: re (kensmith, kib)
ability to retrieve the group list of each process.
Modify procstat's -s option to query this mib when the kinfo_proc
reports that the field has been truncated. If the mib does not exist,
fall back to the truncated list.
Reviewed by: rwatson
Approved by: re (kib)
MFC after: 2 weeks