various fixes
Merge pull request #9 from suhr/master

various fixes