HomeFreeBSD

elfctl: fix -e invalid operation error handling

Description

elfctl: fix -e invalid operation error handling

Validate the operation prior to parsing the feature string, so that e.g.
-e 0x1 reports invalid operation '0' rather than invalid feature 'x11'.
Also make it an error rather than a warning, so that it is not repeated
if multiple files are specified.

(Previously an invalid operation resulted in a segfault.)

MFC after: 3 days
Sponsored by: The FreeBSD Foundation

(cherry picked from commit b8185579f457569640f714b6180522619c2f18ea)

Details

Provenance
emasteAuthored on Feb 15 2022, 3:30 AM
Parents
rGe1465e2e1e06: OpenSSL: Fix the same BIO_FLAGS macro definition
Branches
Unknown
Tags
Unknown