mirror of
https://github.com/Kitware/CMake.git
synced 2026-02-26 10:48:38 -06:00
Merge topic 'separate_arguments-no-args' into release-3.19
747f80fe82 separate_arguments: Fix crash on *_COMMAND with no arguments
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5382
This commit is contained in:
@@ -80,6 +80,11 @@ bool cmSeparateArgumentsCommand(std::vector<std::string> const& args,
|
||||
return false;
|
||||
}
|
||||
|
||||
if (unparsedArguments.empty()) {
|
||||
status.GetMakefile().AddDefinition(var, {});
|
||||
return true;
|
||||
}
|
||||
|
||||
std::string& command = unparsedArguments.front();
|
||||
|
||||
if (command.empty()) {
|
||||
|
||||
Reference in New Issue
Block a user