Diffusion Krita aed25510add2

Fix crash when creating a bezier curve

Authored by dkazakov on Aug 14 2019, 4:08 PM.

Description

Fix crash when creating a bezier curve

The patch basically makes KoShapeManager thread safe by adding
a simple mutex. The problem is that both,
KoCreatePathTool::Private::endPointAtPosition() and
KisRepaintShapeLayerLayerJob access the shape manager in different
threads concurrently, which obviously causes a crash.

BUG:410572
BACKPORT:krita/4.2