Details
-
Bug
-
Resolution: Unresolved
-
P2: Important
-
None
-
6.5.1
-
None
Description
When `QAspectManager:: processFrames` is called it results in calls to `QAbstractAspectPrivate:: syncDirtyFrontEndNodes`. Inside this function a `QMetaObject*` is retrieved and passed to `QAbstractAspectPrivate::mapperForNode` which asserts that the `QMetaObject*` is not null: https://github.com/qt/qt3d/blob/8d2c0edfb87ee14406097d7bf0e57b778cfa39f6/src/core/aspects/qabstractaspect.cpp#L178-L179
In my application there is a case where a number of entities are removed and then new entities are created all at once. When this happens a number of `QShaderProgramBuilder` nodes are processed by `syncDirtyFrontEndNodes` which have nullptr as their `m_typeInfo`, this results in the Q_ASSERT at the beginning of `mapperForNode` to fail.
Looking at the code it seems clear that it was originally written with the expectation that `QMetaObject const* metaObj` might be nullptr. Is it an error to have this assertion? When running my code in a release build it seems to run without issue.