Page MenuHomeFreeBSD

setlogincontext(): Comply to style(9)
ClosedPublic

Authored by olce on May 31 2023, 2:34 PM.
Tags
None
Referenced Files
F142176800: D40346.id123280.diff
Fri, Jan 16, 8:28 PM
Unknown Object (File)
Thu, Jan 15, 4:23 AM
Unknown Object (File)
Wed, Jan 14, 6:20 PM
Unknown Object (File)
Wed, Jan 14, 12:14 PM
Unknown Object (File)
Thu, Jan 1, 11:29 AM
Unknown Object (File)
Sat, Dec 20, 3:44 AM
Unknown Object (File)
Sat, Dec 20, 2:43 AM
Unknown Object (File)
Dec 9 2025, 8:39 PM

Details

Summary

Remove indentation by inverting the big 'if (lc)' and using 'return'.
Use explicit binary operators to produce booleans.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 52083
Build 48974: arc lint + arc unit

Event Timeline

olce requested review of this revision.May 31 2023, 2:34 PM

Update the diff following update of D40344. Same final result.

dchagin added inline comments.
lib/libutil/login_class.c
393–394

if ((flags & LOGIN_SETUMASK) != 0) {

and below

olce retitled this revision from setlogincontext(): Re-format to comply to style(9) to setlogincontext(): Comply to style(9).
olce edited the summary of this revision. (Show Details)

Explicit booleans in tests.

olce marked an inline comment as done.Jun 15 2023, 2:03 PM
olce added inline comments.
lib/libutil/login_class.c
393–394

And above as well. Thanks.

olce marked an inline comment as done.Jun 15 2023, 2:49 PM
lib/libutil/login_class.c
409

There should be a blank line between locals block and first statement.

422

Same

olce marked 2 inline comments as done.Jun 21 2023, 1:41 PM
This revision is now accepted and ready to land.Jan 26 2024, 2:31 PM
This revision was automatically updated to reflect the committed changes.