Fix possible segfaults when changing m_pBehaviour by QSharedPointer. This is a mid term sultion until we see all needs of the effect branch.