mirror of
https://github.com/lubosz/overte.git
synced 2025-04-24 00:13:53 +02:00
Per CR feedback bump to strong ref
This commit is contained in:
parent
654c72fb7e
commit
2505a89b5e
1 changed files with 2 additions and 1 deletions
|
@ -1624,7 +1624,8 @@ void ScriptEngine::loadEntityScript(const EntityItemID& entityID, const QString&
|
|||
QWeakPointer<ScriptEngine> weakRef(sharedFromThis());
|
||||
scriptCache->getScriptContents(entityScript,
|
||||
[this, weakRef, entityScript, entityID](const QString& url, const QString& contents, bool isURL, bool success, const QString& status) {
|
||||
if (!weakRef) {
|
||||
QSharedPointer<ScriptEngine> strongRef(weakRef);
|
||||
if (!strongRef) {
|
||||
qCWarning(scriptengine) << "loadEntityScript.contentAvailable -- ScriptEngine was deleted during getScriptContents!!";
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue