Page MenuHomeFreeBSD

pw: file == NULL check in read_userconfig() is always false
ClosedPublic

Authored by yuripv on Oct 15 2018, 8:45 PM.
Tags
None
Referenced Files
F150992801: D17575.id.diff
Sun, Apr 5, 8:42 AM
Unknown Object (File)
Mon, Mar 30, 3:52 AM
Unknown Object (File)
Fri, Mar 27, 2:32 PM
Unknown Object (File)
Wed, Mar 25, 2:20 AM
Unknown Object (File)
Mon, Mar 23, 9:03 PM
Unknown Object (File)
Thu, Mar 19, 9:52 PM
Unknown Object (File)
Tue, Mar 17, 5:16 AM
Unknown Object (File)
Feb 19 2026, 8:37 AM
Subscribers

Details

Summary

Submitted by Gleb.

read_userconfig() is called from get_userconfig() with non-NULL argument, so the check is always false. Drop the _PATH_PW_CONF definition as well.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Looks good. While you are here, please also replace last "/etc" literal in the pw.c's main() function with _PATH_PWD used with all other places of pw(1) sources.

Looks good. While you are here, please also replace last "/etc" literal in the pw.c's main() function with _PATH_PWD used with all other places of pw(1) sources.

Makes sense.

This revision is now accepted and ready to land.Oct 16 2018, 11:04 AM
This revision was automatically updated to reflect the committed changes.