fix small bugs
Merge pull request #7 from frankmu/master

fix small bugs