Page MenuHomeFreeBSD

Do not recommend sleeping when using vipw(8) non-interactively
Needs ReviewPublic

Authored by 0mp on Jun 18 2020, 1:58 PM.

Details

Reviewers
None
Group Reviewers
manpages
Contributor Reviews (base)
Summary
Do not recommend sleeping when using vipw(8) non-interactively

Before r231383, pw_edit(3) was unable to detect file changes with happening
within the same second. Since that revision, however, pw_edit(3) has
a nanosecond precision of detecting file modifications, so calling "sleep 1"
when using a non-interactive editor with vipw(8) is no longer necessary.

I am not exactly sure if this change is correct, I don't know if a nanosecond is precision can be considered "atomic" on FreeBSD.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint OK
Unit
No Unit Test Coverage
Build Status
Buildable 31793
Build 29354: arc lint + arc unit

Event Timeline

0mp requested review of this revision.Jun 18 2020, 1:58 PM

I would move the "The mechanism for checking for password file modifications requires that the modification time of the password file changes." part under a NOTES section and then remove the BUGS section.

Is this one still active?

In D25338#675153, @bcr wrote:

Is this one still active?

As long as I can get someone to review and accept the change :)

I would move the "The mechanism for checking for password file modifications requires that the modification time of the password file changes." part under a NOTES section and then remove the BUGS section.

mdoc(7) does not have a NOTES section in its standard. It should live in the BUGS section.

Is the change good otherwise?

In D25338#770884, @0mp wrote:

I would move the "The mechanism for checking for password file modifications requires that the modification time of the password file changes." part under a NOTES section and then remove the BUGS section.

mdoc(7) does not have a NOTES section in its standard. It should live in the BUGS section.

Is the change good otherwise?

I'm OK with the change for as long as it keeps the piece of information that I mentioned. I'd prefer under an IMPLEMENTATION NOTES or CAVEATS section, but if not there, let it be BUGS.

In D25338#770884, @0mp wrote:
In D25338#675153, @bcr wrote:

! In D25338#559975, @pstef wrote:

I would move the "The mechanism for checking for password file modifications requires that the modification time of the password file changes." part under a NOTES section and then remove the BUGS section.

That should be "requires that ... change" (no "s" suffix). See https://en.wikipedia.org/wiki/English_subjunctive#Finiteness.