Index: src/core/jobs/job.cpp =================================================================== --- src/core/jobs/job.cpp +++ src/core/jobs/job.cpp @@ -149,7 +149,18 @@ << (mParentJob ? QString::number(reinterpret_cast(mParentJob), 16) : QString()) << QString::fromLatin1(q->metaObject()->className()) << jobDebuggingString(); - s_jobtracker->callWithArgumentList(QDBus::NoBlock, QStringLiteral("jobCreated"), argumentList); + QDBusPendingCall call = s_jobtracker->asyncCallWithArgumentList(QStringLiteral("jobCreated"), argumentList); + + + QDBusPendingCallWatcher *watcher = new QDBusPendingCallWatcher(call, q); + QObject::connect(watcher, &QDBusPendingCallWatcher::finished, q, [](QDBusPendingCallWatcher *w) { + QDBusPendingReply reply = *w; + if (reply.isError() && s_jobtracker) { + s_jobtracker->deleteLater(); + s_jobtracker = nullptr; + } + w->deleteLater(); + }); } }