summaryrefslogtreecommitdiff
path: root/Source/cmCPluginAPI.cxx
diff options
context:
space:
mode:
authorVitaly Stakhovsky <vvs31415@gitlab.org>2020-04-14 10:00:00 -0400
committerBrad King <brad.king@kitware.com>2020-04-14 10:57:17 -0400
commite64fa5f1b611353522ec014192046ab3bf67e69f (patch)
treeee490543c83bc3dea5144ab8971caa661f5b633c /Source/cmCPluginAPI.cxx
parentfc223f986066496654b4f2e392a40264c95cbd68 (diff)
downloadcmake-e64fa5f1b611353522ec014192046ab3bf67e69f.tar.gz
cmSourceFile::GetProperty: return cmProp
Diffstat (limited to 'Source/cmCPluginAPI.cxx')
-rw-r--r--Source/cmCPluginAPI.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/Source/cmCPluginAPI.cxx b/Source/cmCPluginAPI.cxx
index 874efa5d63..697d435aae 100644
--- a/Source/cmCPluginAPI.cxx
+++ b/Source/cmCPluginAPI.cxx
@@ -580,7 +580,8 @@ const char* CCONV cmSourceFileGetProperty(void* arg, const char* prop)
{
cmCPluginAPISourceFile* sf = static_cast<cmCPluginAPISourceFile*>(arg);
if (cmSourceFile* rsf = sf->RealSourceFile) {
- return rsf->GetProperty(prop);
+ cmProp p = rsf->GetProperty(prop);
+ return p ? p->c_str() : nullptr;
}
if (!strcmp(prop, "LOCATION")) {
return sf->FullPath.c_str();