diff options
author | Fabian Kosmale <fabian.kosmale@qt.io> | 2022-09-02 15:35:32 +0200 |
---|---|---|
committer | Qt Cherry-pick Bot <cherrypick_bot@qt-project.org> | 2022-09-02 21:55:18 +0000 |
commit | 9628b73f6c2f5d7dbab582eced8d2a705a49cc5b (patch) | |
tree | c9a8a4a8b3107ba85c07917ba75e67eb092b6d08 /src/quickdialogs2/quickdialogs2/qquickfiledialog.cpp | |
parent | 5ab98872863f65f58789206c750360c06d2600e2 (diff) |
Engine: Fix handling of attached objects in function calls
When we use an attached object as an argument to a function call, we
need to properly extract it from the QmlTypeWrapper. Before this change,
we simpley left the argument pointer as null, which lead to subsequent
crashes when it got dereferenced.
Moreover, treat passing namespaces to functions expecting a QObject as a
TypeError, by returning false from CallArgument::fromValue (used to
crash for the same reason as with the attached object case).
Fixes: QTBUG-106119
Change-Id: Ifa6a32e20a29935aff1f265eb0edd3e35ea1c11b
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
(cherry picked from commit 84483bff4f4d49e5f87abf564021647f2fb2a8d0)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'src/quickdialogs2/quickdialogs2/qquickfiledialog.cpp')
0 files changed, 0 insertions, 0 deletions