Age | Commit message (Collapse) | Author |
|
I dunno if find -execdir should show depth-first like it's doing, bit given
that ubuntu's treating "+" and ";" the same for execdir... eh?
Also, testing "find toys tests -mindepth 2 -execdir echo {} +" against
the toybox source is easy (and why if (revert) fchdir() is needed), but
adding that to the test suite means making a nontrivial hierarchy of files
to test against (don't wanna use the project source because it's expected
to change in ways that would break the tests)... The old "real world data
vs test data" problem.
|
|
Exit immediately if we don't actually have anything to -f --- it's -f's
big brother -F that retries by name rather than by fd.
|
|
|
|
|
|
add function key definitions and shift/ctrl/alt cursor keys.
|
|
checking, and fix up format checking complaints.
Added out(type, value) function to stat to avoid a zillion printf typecasts.
|
|
(not finished yet) plus some error message improvements.
|
|
|
|
The segfault was spotted/fixed by Daniel K. Levy back in September, and again by
Isabella Parakiss yesterday. While we're there, remove the environment
size measurement code (the 128k limit was lifted by linux commit b6a2fea39318,
which went into 2.6.22 released July 2007).
|
|
Lotsa TODOs: Currently exit it with ctrl-c, not q.
Doesn't show totals, PID instead ofTID, PR instead of PRIO (type/pri),
human_readable can't display fixed point, IO isn't a percentage,
COMM instead of COMMAND (so no [kernelthread] brackets), and no
cursor left/right to change sort field...
|
|
"mktemp -u > /dev/full" leave file around.
|
|
The -u flag creates a file, and unlinks it before exiting.
This is usually known as "unsafe mode", or "dry-run" mode.
GNU mktemp has it, as does Busybox's mktemp and likely many others.
|
|
corresponding percentile fields to ps. Move FLAG_ macro usage to ps-specific
code (top/iotop have their own flag contexts). Split init and match code
into shared and ps-specific parts. Fix bug in COMMAND for privileged processes.
|
|
|
|
|
|
|
|
(Moved header a while ago, forgot to check in function move.)
|
|
and add test_scankey.
|
|
|
|
|
|
|
|
|
|
on files opened read-only, so revert last commit (force writeable logic).
|
|
These three are currently available in Android's ps but not in toybox ps.
|
|
|
|
|
|
|
|
(leading underscore version is 1<<NAME_TAG version, with 1LL for >31 shift),
suck lots of magic constants out of ps and use tag macros instead,
redo command line display so there's now 6 variants (CMD COMM ARGS from posix,
NAME CMDLINE from android, and COMMAND for completeness). Document more
cases where posix is nuts or widely ignored.
|
|
and slot numers into a structure. (Keeping multiple arrays in sync may have
been efficient but it was ugly.) Fix duplicate command name copying that
corrupted the name of kernel threads. Tighten up slot[] docs.
|
|
Valgrind complains that we add uninitalized memory to totals[] fields we never
read from. (If we didn't set it in entrylen() we don't use it during display,
they're testing the same flags), but valgrind doesn't understand that.
|
|
out.
Keep the low 32 bits of FLAG_x constants as 32 bit numbers so that at least
on little endian platforms it's still normal 32 bit math outside of lib/args.c.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Includes tests for the new feature, and a failure case for the minimal
perms test as well.
Also some typo fixing / massaging the help text so it fits in 80
columns.
|
|
|
|
move slot[] documentation into C code, add PR %VSZ VIRT RES SHR
|
|
Even though ext2 has a comment that it has to be at the start, I added swap
to the start of the array (oops). The test suite was also wrong (it was
matching the _incorrect_ output).
|
|
|
|
|
|
|
|
instead of carving up toybuf by hand. This makes breaking out the field
conversion logic into its own function less expensive.
|
|
Change readfileat() to pass back length of read.
|
|
1) It read st_dev instead of st_mode.
2) It reversed the semantics of absolute vs minimal ('-' prefixed) tests.
Add tests for these, and move the "unterminated -exec" test into the "Still
fails" section because it's still dumping core for me.
|
|
|
|
Four-digit years were being mangled by the code for two-digit years.
Move all the two-digit year code into the "we only saw two digits" case.
Add some new tests and fix existing tests.
|
|
functions to read major()/minor(), fix printf format warnings in error msg.
|