aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@qt.io>2022-03-24 15:58:51 +0100
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2022-03-25 14:35:03 +0000
commit2f301f4550daa8cf93a788f9adc56b0fec61afbe (patch)
treeff4aec581db8cc0fbe5140d96ff62f289030b9ce
parent4b905b17190248da8db2f2186cb3783397a90e40 (diff)
QML: In captureLookup(), return false if it fails
Otherwise the AOT-compiled code will assume the capture succeeded and fail to get notified when the value changes. This went unnoticed because it only applies to direct mode, the tests for which live in a separate repository. Fixes: QTBUG-102022 Change-Id: I23d94ccbef5b00c4c6837c88970a4e40b05a912a Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> (cherry picked from commit d52e1d609516d0573bea1acf2d73d811ff25f0e9) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
-rw-r--r--src/qml/qml/qqml.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/qml/qml/qqml.cpp b/src/qml/qml/qqml.cpp
index 0d48011810..fddb97e087 100644
--- a/src/qml/qml/qqml.cpp
+++ b/src/qml/qml/qqml.cpp
@@ -997,8 +997,7 @@ bool AOTCompiledContext::captureLookup(uint index, QObject *object) const
return true;
}
-
- return true;
+ return false;
}
bool AOTCompiledContext::captureQmlContextPropertyLookup(uint index) const