various fixes
Merge pull request #6 from wkerzendorf/new_fix

various fixes