Fixed two memory leaks.
Merge pull request #17 from frank4565/master

Fixed two memory leaks.