aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/items/qquickshadereffectsource.cpp
diff options
context:
space:
mode:
authorLaszlo Agocs <laszlo.agocs@qt.io>2021-10-11 15:37:33 +0200
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2021-10-13 05:28:01 +0000
commitf7655ca8731df398353d87f09c9cc59c1ace3b34 (patch)
tree4c91fe24465396778654309b5e3a5426d1a25846 /src/quick/items/qquickshadereffectsource.cpp
parent42c040b64b0b8b9b3ae4d76de1e6ec9d70b1eb5f (diff)
Revert "Fix for possible crash in QSGDefaultLayer::grab"
This reverts commit 1c5de027d0c31d1d6697bd0557128d92207763d8. The fix here is not correct. Calling a QSGRhiLayer function from the gui thread is very wrong and can cause a set of unexpected issues. The Address Sanitizer catches this by recognizing that the render thread is trying to do something with an object destroyed in the meantime on the main thread in the layer->setItem(null) call. The issue the original fix is trying to address needs to be addressed in some different form. Fixes: QTBUG-94975 Change-Id: I46f904026281201fc6d233ed7d3bdc7080934afe Reviewed-by: Christian Strømme <christian.stromme@qt.io> (cherry picked from commit a5f0361622eb08eab6c3474d5fc249d1962e3d1e) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'src/quick/items/qquickshadereffectsource.cpp')
-rw-r--r--src/quick/items/qquickshadereffectsource.cpp8
1 files changed, 0 insertions, 8 deletions
diff --git a/src/quick/items/qquickshadereffectsource.cpp b/src/quick/items/qquickshadereffectsource.cpp
index 4f61d61309..b298ed74da 100644
--- a/src/quick/items/qquickshadereffectsource.cpp
+++ b/src/quick/items/qquickshadereffectsource.cpp
@@ -344,7 +344,6 @@ void QQuickShaderEffectSource::setSourceItem(QQuickItem *item)
d->refFromEffectItem(m_hideSource);
d->addItemChangeListener(this, QQuickItemPrivate::Geometry);
connect(m_sourceItem, SIGNAL(destroyed(QObject*)), this, SLOT(sourceItemDestroyed(QObject*)));
- connect(m_sourceItem, SIGNAL(parentChanged(QQuickItem*)), this, SLOT(sourceItemParentChanged(QQuickItem*)));
} else {
qWarning("ShaderEffectSource: sourceItem and ShaderEffectSource must both be children of the same window.");
m_sourceItem = nullptr;
@@ -364,13 +363,6 @@ void QQuickShaderEffectSource::sourceItemDestroyed(QObject *item)
}
-void QQuickShaderEffectSource::sourceItemParentChanged(QQuickItem *parent)
-{
- if (!parent && m_texture)
- m_texture->setItem(0);
-}
-
-
/*!
\qmlproperty rect QtQuick::ShaderEffectSource::sourceRect