Commit c30a170b authored by Martin Jones's avatar Martin Jones Committed by Qt by Nokia
Browse files

Handle a null source item being provided to ShaderEffect


Change-Id: Ibb4a141349c85738f1710ecaadb8ab78a00372ae
Reviewed-by: default avatarAndrew den Exter <andrew.den-exter@nokia.com>
parent d19be663
No related merge requests found
Showing with 2 additions and 0 deletions
...@@ -413,6 +413,8 @@ void QQuickShaderEffect::setSource(const QVariant &var, int index) ...@@ -413,6 +413,8 @@ void QQuickShaderEffect::setSource(const QVariant &var, int index)
} }
QObject *obj = qVariantValue<QObject *>(var); QObject *obj = qVariantValue<QObject *>(var);
if (!obj)
return;
QQuickItem *item = qobject_cast<QQuickItem *>(obj); QQuickItem *item = qobject_cast<QQuickItem *>(obj);
if (!item || !item->isTextureProvider()) { if (!item || !item->isTextureProvider()) {
qWarning("ShaderEffect: source uniform [%s] is not assigned a valid texture provider: %s [%s]", qWarning("ShaderEffect: source uniform [%s] is not assigned a valid texture provider: %s [%s]",
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment