Use with statement to close file handle
Merge pull request #25 from svisser/patch-2

Use with statement to close file handle