Merge pull request #406 from muggenhor/warning-fixes