Page MenuHomeFreeBSD

veriexec: fixed usage and getopt issue on armv6
AcceptedPublic

Authored by sebastien.bini_stormshield.eu on Sep 7 2022, 8:06 AM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Apr 8, 9:51 PM
Unknown Object (File)
Dec 10 2023, 7:16 PM
Unknown Object (File)
Dec 7 2023, 5:02 PM
Unknown Object (File)
Nov 10 2023, 12:44 AM
Unknown Object (File)
Oct 29 2023, 8:14 PM
Unknown Object (File)
Oct 10 2023, 7:15 PM
Unknown Object (File)
Oct 8 2023, 11:32 PM
Unknown Object (File)
Sep 6 2023, 4:12 AM
Subscribers

Details

Reviewers
wma
mw
imp
Summary

This fixes an issue introduced by https://reviews.freebsd.org/D33246

getopt returns an int, which was stored inside c of type char. c was then compared to -1. All those type conversions worked fine on our amd64 systems, but not on armv6 architecture.

The -1 returned by getopt, stored in c, never successfully compared to -1, causing the program to fall into the usage error in the default: switch case.

I also fixed the usage function, as -C takes a path as parameter.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 47276
Build 44163: arc lint + arc unit