summaryrefslogtreecommitdiffstats
path: root/qmake
diff options
context:
space:
mode:
authorQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2019-07-20 01:00:13 +0200
committerQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2019-07-20 01:00:13 +0200
commit124b5b8108e181eb4860dd25d88dd641dca32e39 (patch)
treedbbd1423200e0ef23e186f04f9421df1b6b765f7 /qmake
parent69ef6e821287d324459336dd1292d19d272386b8 (diff)
parenta96a64be2dc3110d140e43d2cf85454d9fc998b8 (diff)
Merge remote-tracking branch 'origin/5.12' into 5.13
Diffstat (limited to 'qmake')
-rw-r--r--qmake/generators/makefile.cpp6
-rw-r--r--qmake/library/proitems.h5
2 files changed, 6 insertions, 5 deletions
diff --git a/qmake/generators/makefile.cpp b/qmake/generators/makefile.cpp
index a963c38178..a45b676d5f 100644
--- a/qmake/generators/makefile.cpp
+++ b/qmake/generators/makefile.cpp
@@ -3426,9 +3426,9 @@ MakefileGenerator::writePkgConfigFile()
t << endl;
// requires
- const QString requires = project->values("QMAKE_PKGCONFIG_REQUIRES").join(' ');
- if (!requires.isEmpty()) {
- t << "Requires: " << requires << endl;
+ const QString requiresString = project->values("QMAKE_PKGCONFIG_REQUIRES").join(' ');
+ if (!requiresString.isEmpty()) {
+ t << "Requires: " << requiresString << endl;
}
t << endl;
diff --git a/qmake/library/proitems.h b/qmake/library/proitems.h
index 0e0bebddc7..936c729ff8 100644
--- a/qmake/library/proitems.h
+++ b/qmake/library/proitems.h
@@ -432,11 +432,12 @@ public:
ProFunctionDef(const ProFunctionDef &o) : m_pro(o.m_pro), m_offset(o.m_offset) { m_pro->ref(); }
ProFunctionDef(ProFunctionDef &&other) Q_DECL_NOTHROW
: m_pro(other.m_pro), m_offset(other.m_offset) { other.m_pro = nullptr; }
- ~ProFunctionDef() { m_pro->deref(); }
+ ~ProFunctionDef() { if (m_pro) m_pro->deref(); }
ProFunctionDef &operator=(const ProFunctionDef &o)
{
if (this != &o) {
- m_pro->deref();
+ if (m_pro)
+ m_pro->deref();
m_pro = o.m_pro;
m_pro->ref();
m_offset = o.m_offset;