Diffusion Krita e260107274f4

Fix flake tests under asan

Authored by tusooaw on Jul 6 2019, 1:36 PM.

Description

Fix flake tests under asan

ShapeGroupContainerModel::remove() will call KoShapeGroup::invalidateSizeCache(),
even when the shape group is going to be destroyed. This method is called after
KoShapeGroup's destructor, so at this time we no longer have access to members of
KoShapeGroup, i.e. its d-pointer. So this call will cause access violation as the
instance QScopedPointer<Private> d in KoShapeGroup has already been destroyed.

This is a result of getting rid of derived d-pointers, because if we use a derived
d-pointer, it only gets destroyed in the ancestor class (KoShape). We temporarily
fix this problem by manually call model()->deleteOwnedShapes() in KoShapeGroup's
destructor.

Details

Committed
tusooawJul 6 2019, 1:36 PM
Parents
R37:67cc69ceb3fb: Fix debug build temporarily
Branches
Unknown
Tags
Unknown
References
refs/keep-around/e260107274f447fdce8a1dc149704d3c81f930f8