fix issue #9 and #10, and update CHANGELOG.md