summaryrefslogtreecommitdiffstats
path: root/Source/cmMakefile.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2009-02-02 18:27:30 (GMT)
committerBrad King <brad.king@kitware.com>2009-02-02 18:27:30 (GMT)
commit7d6a5e097f17720ed21fe5faac1759bf387c7880 (patch)
tree75128c86941506cf87608940d62e5de9e43423a2 /Source/cmMakefile.cxx
parentcc2092d5bb282dd4010b11a289638a243f7961e2 (diff)
downloadCMake-7d6a5e097f17720ed21fe5faac1759bf387c7880.zip
CMake-7d6a5e097f17720ed21fe5faac1759bf387c7880.tar.gz
CMake-7d6a5e097f17720ed21fe5faac1759bf387c7880.tar.bz2
ENH: More robust property lookup
This teaches cmMakefile::GetProperty and cmake::GetProperty methods to return NULL when the property name is NULL, making them more robust and consistent with the behavior of cmTarget::GetProperty.
Diffstat (limited to 'Source/cmMakefile.cxx')
-rw-r--r--Source/cmMakefile.cxx4
1 files changed, 4 insertions, 0 deletions
diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx
index fabfd35..870fd6f 100644
--- a/Source/cmMakefile.cxx
+++ b/Source/cmMakefile.cxx
@@ -3162,6 +3162,10 @@ const char *cmMakefile::GetProperty(const char* prop)
const char *cmMakefile::GetProperty(const char* prop,
cmProperty::ScopeType scope)
{
+ if(!prop)
+ {
+ return 0;
+ }
// watch for specific properties
static std::string output;
output = "";