Commit Briefs
fix loop for writes
don't write more than fetched. The code wrote up to sizeof(buf), but it may try to write more than the data sent, which is r (<= sizeof(buf)).
include test in the distribution tarball
while here also delete the two remaining makefiles from before the -portable merge.
mark manpages as dist_man?_MANS instead of man?_MANS
fixes `make distcheck'. it's so GNU to not ship manpages by default :/
CLOEXEC of all opened fds
since we may want to spawn other programs, mark every file descriptor as cloexec. Fortunately, we don't end up opening many of them!
ftp: add `page' command
The `page' command fetches a file and displays it using less(1). To do this, refactor fetch_fid to accept a file descriptor and add a spawn utility function.
simplify TAILQ_INSERT dance
when a tailq is proprerly initialized, there's no need to check if it's empty and insert in head position.
simplify client proc bootstrap
Drop the IMSG_AUTH_DIR imsg type and stuff everything in a struct kd_auth_proc that gets sent via IMSG_AUTH. Tweak the necessary bits to compile. While here also start documenting what data we send over which imsg. As an added benefit, now we're sending fixed-size messages instead of variable length strings.