Merge pull request #20 from fusijie/master

Fixed some bugs