summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorDavid Cole <david.cole@kitware.com>2012-07-12 20:00:18 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2012-07-12 20:00:18 (GMT)
commit7a3a5eb4588d05fb3aff97123f8f66da1a99ea33 (patch)
tree7fdc7befc624c9bffd9ee3063e388e4a582e2c81 /Source
parent457041e5b31c315b72ec49b54eb4367f0850086a (diff)
parent2e99949ccb216c59ff1932bc3773654e9ae54419 (diff)
downloadCMake-7a3a5eb4588d05fb3aff97123f8f66da1a99ea33.zip
CMake-7a3a5eb4588d05fb3aff97123f8f66da1a99ea33.tar.gz
CMake-7a3a5eb4588d05fb3aff97123f8f66da1a99ea33.tar.bz2
Merge topic 'include-command-empty-filename'
2e99949 include: Ignore empty string as file name (#13388)
Diffstat (limited to 'Source')
-rw-r--r--Source/cmIncludeCommand.cxx7
1 files changed, 7 insertions, 0 deletions
diff --git a/Source/cmIncludeCommand.cxx b/Source/cmIncludeCommand.cxx
index 0ac6df4..0d5f67b 100644
--- a/Source/cmIncludeCommand.cxx
+++ b/Source/cmIncludeCommand.cxx
@@ -70,6 +70,13 @@ bool cmIncludeCommand
}
}
+ if(fname.empty())
+ {
+ this->Makefile->IssueMessage(cmake::AUTHOR_WARNING,
+ "include() given empty file name (ignored).");
+ return true;
+ }
+
if(!cmSystemTools::FileIsFullPath(fname.c_str()))
{
// Not a path. Maybe module.