mirror of
https://github.com/reactos/CMake.git
synced 2024-11-25 04:29:52 +00:00
FPHSA: Avoid if() dereferencing of quoted variable
Legacy invocations may pass a variable name where "DEFAULT_MSG" belongs. When comparing FPHSA_FAIL_MESSAGE to "DEFAULT_MSG", use a leading "x" on both sides to avoid mistaking the value of the message for a variable name.
This commit is contained in:
parent
425acc522f
commit
e177e7affb
@ -201,7 +201,7 @@ function(FIND_PACKAGE_HANDLE_STANDARD_ARGS _NAME _FIRST_ARG)
|
|||||||
|
|
||||||
# now that we collected all arguments, process them
|
# now that we collected all arguments, process them
|
||||||
|
|
||||||
if("${FPHSA_FAIL_MESSAGE}" STREQUAL "DEFAULT_MSG")
|
if("x${FPHSA_FAIL_MESSAGE}" STREQUAL "xDEFAULT_MSG")
|
||||||
set(FPHSA_FAIL_MESSAGE "Could NOT find ${_NAME}")
|
set(FPHSA_FAIL_MESSAGE "Could NOT find ${_NAME}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user