| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
r323275:
Add basic tests for chflags, mkdir, rcp, and rmdir
Add basic command line parsing test coverage for these utilities. The tests
were automatically generated based on their man pages. These tests can be
expanded by hand for more thorough coverage. The aim is to generate very
basic amount of test coverage for all the utilities in the base system.
Submitted by: shivansh
Reviewed by: asomers, brooks
Sponsored by: Google, Inc (GSoC 2017)
Differential Revision: https://reviews.freebsd.org/D12036
r324112:
Fix Makefile entries from r323275
Reported by: Vladimir Zakharov <zakharov.vv@gmail.com>
Reviewed by: ngie
X-MFC-With: 323275
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Document "tdnam" keyword to ps(1), and add "tdname" alias.
MFC r324429:
Fix long name (used by libxo) for the "tdnam" ps(1) keyword.
MFC r324430:
Undocument "tdnam" (leaving it as an alias), and rename the column
to TDNAME.
|
|
|
|
|
|
|
|
| |
Fix kvm_getprocs(3) error reporting in ps(1).
Previously it just didn't work at all - kvm_getprocs(3) doesn't update
the &nentries when it returns NULL. The end result was that ps(1) showed
garbage data instead of reporting kinfo_proc size mismatch.
|
|
|
|
| |
Hint that the "-o emul" option for ps(1) shows the ABI.
|
|
|
|
| |
Make ps(1) flag processes in capsicum(4) capability mode with "C".
|
|
|
|
|
|
|
|
|
|
| |
Reflect realtime and idle priorities in ps(1) state flags, same like
we do for the usual nice values. It could be argued that they should
use another set of indicators, since the underlying mechanism is
different, but they match the description in the manual page, and so
I think it's ok to not overcomplicate things.
PR: 81757
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Remove SUBDIR ordering/uniquifying in *bin/Makefile
After the addition of SUBDIR.yes, uniquifying/ordering the SUBDIRs doesn't
make a whole lot of sense, and it's in effect a half measure.
Ordering SUBDIR (after adding SUBDIR.yes to it) in bsd.subdir.mk is a
separate change that warrants more discussion/testing, because while
the SUBDIR_PARALLEL work largely fixed dependency ordering for SUBDIRs,
there might be downstream FreeBSD consumers that rely on the SUBDIR
ordering.
|
|
|
|
|
|
|
|
| |
localtime(3) returns NULL when passed an invalid time_t but date(1)
previously did not handle it. Exit with an error in that case.
PR: 220828
Submitted by: VinÃcius Zavam
|
|
|
|
|
|
|
|
|
|
| |
style fixes in bin/echo/tests
Submitted by: shivansh
Reviewed by: asomers
X-MFC-With: 319626
Sponsored by: Google, Inc (GSoC 2017)
Differential Revision: https://reviews.freebsd.org/D11318
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
r321949:
Add expected failures for ZFS
- :f_flag fails on ZFS because UF_IMMUTABLE isn't supported [1].
- :v_flag fails on ZFS because the mode for foo is [always] updated
unnecessarily.
get_filesystem(..) (supporting function that was added to the test script)
is based on equivalent logic in usr.bin/extattr/tests/extattr_test.sh .
PR: 221189 [1], 221188 [2]
r321950:
Always use first parameter passed to get_filesystem(..) instead of discarding it
and using `.` instead.
MFC with: r321949
PR: 221189 [1], 221188 [2]
r322101:
Don't check result of chflags in f_flag_cleanup()
This will prevent false positives from occurring if the test is run on
ZFS since ZFS doesn't support fflags throbbing like UFS.
PR: 221189
MFC with: r321949
|
|
|
|
|
| |
Use the "tree" word in ps(1) -d option description, to make it easier
to find.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
r302500 (by cem):
dd(1): Enable access to SIZE_T_MAX character devices
On machines where SIZE_T_MAX exceeds OFF_MAX (signed 64-bit), permit seeking
character devices to negative off_t values. This enables dd(1) to interact
with kernel KVA in /dev/kmem on amd64, for example.
r319339 (by asomers):
Fix integer overflow detection in dd
dd(1) tried to detect whether the seek offset would overflow, but it failed
to account for the case where the provided argument was negative and the
file was a regular file (negative seeks are allowed for character devices).
I fixed it, and added a regression test.
CID: 1368659
r319543:
Stylistic tweaks
Move opening braces of functions from the last column to column 0.
MFC with: r319339
r319544:
Mark :seek_overflow as an expected failure
MFC with: r319339
PR: 219757
r319551 (by asomers):
Fix bin/dd/dd2_tests:seek_overflow on UFS and TMPFS
Split the postive and negative parts into separate test cases. The positive
test case can only run on ZFS, because only ZFS supports files that large.
PR: 219757
r321138:
Remove unnecessary make logic added in r319339
This makes the change cleaner and easier to backport to ^/stable/10.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
r303212 (by bdrewery):
Move chown tests to proper path
r319642:
Add some basic tests for chmod(1)
r319830:
Add more simple positive tests for chown(1)
The tests are largely symmetric with the tests for chmod(1)--added in r319642.
Remove chown-f_test (added in r268030) since the test coverage is now being
provided by `chown_test`.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
r320172:
ln(1): fix -F behavior
When '-F' option is used, the target directory needs to be unlinked.
Currently, the modified target ("target/source") is being unlinked, and
since it doesn't yet exist, the original target isn't removed.
This is fixed by skipping the block where target is modified to
"target/source" when '-F' option is set.
Hence, a symbolic link (with the same name as of the original target) to
the source_file is produced.
Update the test for ln(1) to reflect fix for option '-F'
PR: 219943
r320173:
Don't expect :sF_flag to fail anymore
While here, also add a check to verify that the link target
is updated in the testcase
MFC with: r320172
PR: 219943
|
|
|
|
| |
ln(1): wordsmith -F option description
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
r319855:
Use readlink(1)/stat(1) to query symlinks instead of file(1)
file(1) can be compiled out of the system via MK_FILE == no, and the
output isn't guaranteed to be stable. It's better to use stat(1)/readlink(1)
instead to query symlink/file paths.
MFC with: r319714, r319854
r319856:
Add a testcase for `ln -sF`
The testcase fails today, so mark it with atf_expect_fail: in
particular, the target (B) isn't being unlinked and the documentation
doesn't suggest special handling for directories. Thus, there's either
a doc or an implementation bug in ln(1) that needs to be resolved.
MFC with: r319714, r319854, r319855
PR: 219943
r319858:
Style fixes: clean up leading whitespace (8 single column spaces -> \t)
MFC with: r319714, r319854, r319855, r319856
|
|
|
|
|
|
|
|
|
| |
Add basic tests for echo(1)
Verify that echo(1) does not...
- ... print the trailing newline character with option '-n'.
- ... print the trailing newline character when '\c' is appended to
the end of the string.
|
|
|
|
| |
Add testcases for `cat -b`
|
|
|
|
|
|
|
|
|
| |
Add additional testcases for cat(1)
Verify the following additional cases:
- -s (in isolation, in addition to the -se testcase obtained via the
NetBSD test).
- -vt
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
r319714:
Add tests for ln(1)
* Verify that when creating a hard link to a symbolic link, '-L' option
creates a hard link to the target of the symbolic link
* Verify that when creating a hard link to a symbolic link, '-P' option
creates a hard link to the symbolic link itself
* Verify that if the target file already exists, '-f' option unlinks it so
that link may occur
* Verify that if the target file or directory is a symbolic link, '-shf'
option prevents following the link
* Verify that if the target file or directory is a symbolic link, '-snf'
option prevents following the link
* Verify that '-s' option creates a symbolic link
* Verify that '-w' option produces a warning if the source of a symbolic
link does not currently exist
Submitted by: shivansh
Reviewed by: asomers, ngie
Sponsored by: Google, Inc (GSoC 2017)
Differential Revision: https://reviews.freebsd.org/D11084
r319854:
bin/ln: Set umask appropriately before creating files for testing
These changes were missed in D11084
Submitted by: shivansh
Reviewed by: asomers
X-MFC-With: 319714
Sponsored by: Google, Inc (GSoC 2017)
Differential Revision: https://reviews.freebsd.org/D11158
|
|
|
|
| |
Add deprecation notices for all rcmd tools
|
|
|
|
|
|
| |
bin: normalize paths using SRCTOP-relative paths or :H when possible
This simplifies make logic/output
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Convert absolute links to relative links.
Style.Makefile(9) has been ignored to produce minimal diffs.
MFC r314837
The relative symlink fix causes downstream issues for
EMC DELL Isilon so revert the relative symlink fix
pending a better solution.
Reported by: ngie
MFC r315091
Revert r314833 until the problem with INSTALL_RSYMLINKS can be found
as it appears to break arm release builds.
PR: 217705
Reported by: cyclaero@gmail.com
Approved by: grehan (mentor)
|
|
|
|
| |
.Xr resizewin from stty(1) man page.
|
|
|
|
|
|
|
|
| |
settings.
After executing a builtin with different locale settings such as
LC_ALL=C true
SIGINT handling was left disabled indefinitely.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fix indentation in dd(1)
Quoting http://mdocml.bsd.lv/mdoc/details/width.html
Do not use macros in the argument specifying the width,
since that's not portable. While GNU troff can handle it,
mandoc cannot.
Sponsored by: Dell EMC
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Update tcsh to 6.20.00
MFC r315952:
Update tcsh to vendor git b605cb561d
Vendor changes:
1. PR/471: Daiki Ueno: Delay interpreting arginp until we've processed
our startup files (which can change the NLS environment).
2. Fix type of read in prompt confirmation (eg. rmstar) (David Kaspar).
3. Fix out of bounds read (Brooks Davis)
(reproduce by starting tcsh and hitting tab at the prompt).
4. Don't play pointer tricks that are undefined in modern c
(Brooks Davis).
|
|
|
|
|
|
|
|
|
| |
r314886:
pwait: Add a -t flag to specify a timeout before exiting, and tests.
r314943:
Remove unneeded -x from tests.
r314944:
Rename some tests to end in _test.
|
|
|
|
| |
Don't kill pid -1 on overflow from strtol(3).
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The parsed internal representation of words consists of a byte string with a
list of nodes (commands in command substitution). Each unescaped CTLBACKQ or
CTLBACKQ | CTLQUOTE byte corresponds to an entry in the list.
If param in ${param#%##%%word} is not set, the word is not expanded (in a
deviation of POSIX shared with other ash variants and ksh93). Erroneously,
the pointer in the list of commands (argbackq) was not advanced. This caused
the wrong command to be executed later if the outer word contained another
command substitution.
Example:
echo "${unsetvar#$(echo a)}$(echo b)"
wrote "a" but should write "b".
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Code like t=$(stat -f %m "$file") segfaulted if -T was active and a trap
was taken while the shell was waiting for the child process to finish.
What happened was that the dotrap() call in waitforjob() was hit. This
re-entered command execution (including expand.c) at a point not expected by
expbackq(), and global state (unallocated stack string and argbackq) was
corrupted.
To fix this, change expbackq() to prepare for command execution to be
re-entered.
Reported by: bdrewery
|
| |
|
|
|
|
| |
Use uintmax_t to print st_nlink.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
r313659:
Remove space at and of line
Reported by: make manlint
MFC after: 2 days
r313660:
Remove empty Li
Reported by: make manlint
MFC after: 2 days
r313661:
Escape Ss to avoid confusion by mdoc parser with the Ss macro
Reported by: make manlint
MFC after: 2 days
r313662:
Add missing -width after -Bl -tag
Reported by: make manlint
MFC after: 2 days
r313663:
Add missing section after .Xr reference
r313664:
Escape No to avoid confusion with the No macro
r313665:
Remove useless .Pp after the .Sh macro and remove empty line
r313666:
Remove empty space at EOL and escept Ed
r313667:
Remove spaces at EOL and sort correctly the SEE ALSO section
r313668:
Add missing section in manpage reference
r313669:
Properly use .An macro before Authors name
r313670:
Escape Sm to avoid confusion with Sm macro
r313671:
Use correct date format
r313672:
Remove useless Li macro
r313673:
Remove spaces at end of line
Reported by: make manlint
|
|
|
|
|
|
|
|
|
| |
First version of UNIX to include dd found using TUHS
http://minnie.tuhs.org/cgi-bin/utree.pl?file=V5/usr/source/s1/dd.c
PR: 211777
Approved by: bcr (mentor)
Differential Revision: https://reviews.freebsd.org/D8104
|
|
|
|
|
|
|
|
|
|
| |
Add a note of it.
http://minnie.tuhs.org/cgi-bin/utree.pl?file=V3/man/man8/kill.8
PR: 211786
Approved by: bcr (mentor)
Obtained from: TUHS
Differential Revision: https://reviews.freebsd.org/D8105
|
|
|
|
| |
Use type-independent formats for printing nlink_t and ino_t.
|
|
|
|
|
|
|
|
| |
Fix ls_tests:o_flag with ZFS TMPDIR
Unlike UFS or TMPFS, ZFS sets uarch automatically whenever a file is
updated. The test must explicitly clear uarch to be portable across
filesystems. Also, it doesn't need to run as root.
|
|
|
|
|
|
|
|
|
|
| |
pax(1): Fix a bug with archives smaller than 512 bytes.
The problem here is that the archive is too short (< 512 bytes). The
buffer routines, try to read at least 512 bytes, even when we try to
determine what format file we have, which is wrong.
Obtained from: NetBSD (CVS rev 1.26)
|
|
|
|
|
|
|
| |
ed(1): Prevent possible overflows during allocation.
Make sure the parameters used for malloc(3) can hold size_t sizes.
This should help ed(1) handle bigger data in the future.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
r310088:
Put the undocumented df feature of mounting filesystems from device
nodes
under an ifdef. Leave enabled.
Reviewed by: cem
Sponsored by: DARPA, AFRL
Differential Revision: https://reviews.freebsd.org/D8513
r310090:
Mount filesystems without executable permissions since they should never
be used.
Reviewed by: cem
Sponsored by: DARPA, AFRL
Differential Revision: https://reviews.freebsd.org/D8513
r310095:
Use nmount(2) rather than the obsolete mount(2).
Reviewed by: cem
Sponsored by: DARPA, AFRL
Differential Revision: https://reviews.freebsd.org/D8513
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Export the whole thread name in kinfo_proc
kinfo_proc::ki_tdname is three characters shorter than
thread::td_name. Add a ki_moretdname field for these three
extra characters. Add the new field to kinfo_proc32, as well.
Update all in-tree consumers to read the new field and assemble
the full name, except for lldb's HostThreadFreeBSD.cpp, which
I will handle separately. Bump __FreeBSD_version.
Sponsored by: Dell EMC
|
|
|
|
|
| |
r309238: Plug a potential memory leak.
r309239: style(9).
|
|
|
|
|
| |
PR: 213665
Submitted by: Pawel Worach <pawel.worach@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Update contrib/netbsd-tests with new content from NetBSD
This updates the snapshot from 09/30/2014 to 08/11/2016
This brings in a number of new testcases from upstream, most
notably:
- bin/cat
- lib/libc
- lib/msun
- lib/libthr
- usr.bin/sort
lib/libc/tests/stdio/open_memstream_test.c was moved to
lib/libc/tests/stdio/open_memstream2_test.c to accomodate
the new open_memstream test from NetBSD.
Tested on: amd64 (VMware fusion VM; various bare metal platforms); i386 (VMware fusion VM); make tinderbox
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
r308443:
Add -d flag that prints domain only.
PR: 212875
Submitted by: Ben RUBSON <ben.rubson@gmail.com>
Reviewed by: pi
r308459:
Fix missing '-' for the flags -s and -d on both manpage and usage.
Reported by: garga, bde
r308462:
Add flag -B which does the same like batch mode but without exiting after
print. Also add a new flag -s that add blocks size to statistics.
PR: 198347, 212726
Submitted by: Ben RUBSON <ben.rubson@gmail.com>
Tested by: pi
MFC After: 2 weeks.
r308478:
We can't use protect(1) inside a jail(8)!
To avoid have warning for services that are using oomprotect, oomprotect
will only be applied on services that won't run inside jails.
Reported by: allanjude
MFC after: 2 weeks.
r308786:
rc.subr: Swap checks so we only fork sysctl if *_oomprotect is set.
|
|
|
|
|
|
|
|
|
| |
Add history section for test(1)
http://minnie.tuhs.org/cgi-bin/utree.pl?file=V7/usr/src/cmd/test.c
PR: 211789
Approved by: bcr (mentor)
Differential Revision: https://reviews.freebsd.org/D8104
|
|
|
|
|
|
|
|
|
| |
Add history section for stty(1)
http://minnie.tuhs.org/cgi-bin/utree.pl?file=V3/man/man1/stty.1
PR: 211788
Approved by: bcr (mentor)
Differential Revision: https://reviews.freebsd.org/D8104
|
|
|
|
|
|
|
|
|
| |
Add history section of pwd(1)
http://minnie.tuhs.org/cgi-bin/utree.pl?file=V5/usr/source/s2/pwd.c
PR: 211787
Approved by: bcr (mentor)
Differential Revision: https://reviews.freebsd.org/D8104
|