firmware: Fix inverted FIRMWARE_GET_NOWARN logic
The try_binary_file() function has inverted logic for the FIRMWARE_GET_NOWARN flag. When the flag is set (meaning "don't warn"), the code sets warn=true and makes noise anyway. Invert the assignment to warn to correctly suppress warnings when FIRMWARE_GET_NOWARN is set. Reviewed by: kevans Differential Revision: https://reviews.freebsd.org/D54955
This commit is contained in:
committed by
Kyle Evans
parent
b249cb2b18
commit
fdcd67be82
@@ -281,7 +281,7 @@ try_binary_file(const char *imagename, uint32_t flags)
|
||||
int oflags;
|
||||
size_t resid;
|
||||
int error;
|
||||
bool warn = flags & FIRMWARE_GET_NOWARN;
|
||||
bool warn = (flags & FIRMWARE_GET_NOWARN) == 0;
|
||||
|
||||
/*
|
||||
* XXX TODO: Loop over some path instead of a single element path.
|
||||
|
||||
Reference in New Issue
Block a user