summaryrefslogtreecommitdiffstats
path: root/Source/cmQTWrapCPPCommand.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmQTWrapCPPCommand.cxx')
-rw-r--r--Source/cmQTWrapCPPCommand.cxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/Source/cmQTWrapCPPCommand.cxx b/Source/cmQTWrapCPPCommand.cxx
index cc4df8f..795c2ee 100644
--- a/Source/cmQTWrapCPPCommand.cxx
+++ b/Source/cmQTWrapCPPCommand.cxx
@@ -5,6 +5,7 @@
#include "cmCustomCommandLines.h"
#include "cmExecutionStatus.h"
#include "cmMakefile.h"
+#include "cmProperty.h"
#include "cmRange.h"
#include "cmSourceFile.h"
#include "cmStringAlgorithms.h"
@@ -39,7 +40,8 @@ bool cmQTWrapCPPCommand(std::vector<std::string> const& args,
cmStrCat(mf.GetCurrentBinaryDirectory(), "/moc_", srcName, ".cxx");
cmSourceFile* sf = mf.GetOrCreateSource(newName, true);
if (curr) {
- sf->SetProperty("ABSTRACT", curr->GetProperty("ABSTRACT"));
+ cmProp p = curr->GetProperty("ABSTRACT");
+ sf->SetProperty("ABSTRACT", p ? p->c_str() : nullptr);
}
// Compute the name of the header from which to generate the file.