Some fixes

You find all details in the commit messages.