summaryrefslogtreecommitdiffstats
path: root/Source/cmFileCommand.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmFileCommand.cxx')
-rw-r--r--Source/cmFileCommand.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/Source/cmFileCommand.cxx b/Source/cmFileCommand.cxx
index 45fba8b..8f2ebf5 100644
--- a/Source/cmFileCommand.cxx
+++ b/Source/cmFileCommand.cxx
@@ -2555,8 +2555,9 @@ bool HandleGenerateCommand(std::vector<std::string> const& args,
return false;
}
const bool inputIsContent = arguments.ParsedKeywords[1] == "CONTENT"_s;
- if (!inputIsContent && arguments.ParsedKeywords[1] == "INPUT") {
+ if (!inputIsContent && arguments.ParsedKeywords[1] != "INPUT") {
status.SetError("Unknown argument to GENERATE subcommand.");
+ return false;
}
std::string const& input =
inputIsContent ? *arguments.Content : *arguments.Input;