Start fixing threading situation, see #51