Hi Theo, Theo de Raadt wrote on Fri, Oct 30, 2020 at 12:10:41PM -0600:
> Yes, that diff is a whole bunch of TOCTUO. > > If this was going to be changed, it should be in the kernel. > > But I don't know if it should be changed yet, which is why I asked > a bunch of questions. > > Stepping back to the man page change, we could decide that accton > should continue to behave how it does, and this conversation started > because the man page fell into the trap of documenting the rc scripts > RATHER than documenting accton. Given that nobody seems in a rush to patch the kernel, i suggest to improve the accton(8) manual page for now. In particular, that manual page lacks the required EXIT STATUS section, which happens to be a natural place for mentioning what happens if the file does not exist. As usual, an EXAMPLES section is not strictly required, but in this case, it seems useful to me, to save people from having to inspect /etc/mtree/special for the recommended file permissions. OK? Ingo Index: accton.8 =================================================================== RCS file: /cvs/src/usr.sbin/accton/accton.8,v retrieving revision 1.12 diff -u -r1.12 accton.8 --- accton.8 2 Nov 2020 13:58:44 -0000 1.12 +++ accton.8 2 Nov 2020 14:19:43 -0000 @@ -64,6 +64,17 @@ .It Pa /var/account/acct default accounting file .El +.Sh EXIT STATUS +.Ex -std +For example, it is an error if the +.Ar file +does not exist. +.Sh EXAMPLES +The following commands enable accounting if it was never used before: +.Bd -literal -offset 4n +# install -o root -g wheel -m 0644 /dev/null /var/account/acct +# accton /var/account/acct +.Ed .Sh SEE ALSO .Xr lastcomm 1 , .Xr acct 2 ,