Skip to content

Commit 751ec46

Browse files
committed
[commontk] addDecorators: Check for null object
1 parent 5e97dd8 commit 751ec46

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/PythonQt.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1569,6 +1569,10 @@ PythonQtClassInfo* PythonQtPrivate::currentClassInfoForClassWrapperCreation()
15691569

15701570
void PythonQtPrivate::addDecorators(QObject* o, int decoTypes)
15711571
{
1572+
if (!o)
1573+
{
1574+
return;
1575+
}
15721576
o->setParent(this);
15731577
int numMethods = o->metaObject()->methodCount();
15741578
for (int i = 0; i < numMethods; i++) {

0 commit comments

Comments
 (0)