diff options
author | dougb <dougb@FreeBSD.org> | 2012-09-04 16:00:51 +0000 |
---|---|---|
committer | dougb <dougb@FreeBSD.org> | 2012-09-04 16:00:51 +0000 |
commit | 83d50f9dde1f19f5ec2c458bb6d08a5538ae416c (patch) | |
tree | e07537e27c197f49dfdbba22093733cfecd999e4 /bin/mv | |
parent | b357c43c75b7875a5dbfbd6e6c28e0f15ed74252 (diff) | |
download | FreeBSD-src-83d50f9dde1f19f5ec2c458bb6d08a5538ae416c.zip FreeBSD-src-83d50f9dde1f19f5ec2c458bb6d08a5538ae416c.tar.gz |
1. Use install -d to create the entropy_dir if missing so that we can do it
all in one command, with no permissions race.
2. Simplify the rotation logic by cd'ing into the directory, with a test
to make sure that it succeeds.
3. Remove any files numbered higher than entropy_save_num. This helps when
the user reduces the number, and may be useful for other purposes down
the road.
4. Simplify the rotation logic by first testing the common case (it's a
regular file) then testing if something else exists with the same name
using elif. Also switch from using jot to simpler countdown format.
5. Fix logger lines and error messages to be more consistent, and wrap the
code more consistently in the 80 column range. The "not a regular file"
error message was mistakenly wrapped entirely in "quotes" which caused
logger to include line-wrapping whitespace. Change that to wrap only
the variables in quotes, which is both consistent and works better.
6. Update copyright to reflect the fact that changes were made this year.
Parts of 2-4 were taken from etc/periodic/daily/310.accounting
Diffstat (limited to 'bin/mv')
0 files changed, 0 insertions, 0 deletions