Error handling in acpiconf is spotty at best. In many instances we trust the result from atoi() without checking, and mutually exclusive arguments are not handled.
This patch updates acpiconf to use strol instead of atoi(), with error checking. It also takes care of arguments that are mutually exclusive, instead of trying to run all commands.
Details
Details
- Reviewers
emaste - Commits
- rS326733: Improve options and error handling.
Compile test, as well as run through all arguments and see that they still work. Purposely use mutually exclusive arguments, and provide stuff that strol() can't interpret as a number, to see that the error handling works.
Diff Detail
Diff Detail
- Repository
- rS FreeBSD src repository - subversion
- Lint
Lint Skipped - Unit
Tests Skipped - Build Status
Buildable 13451