[Helpers] Fix a leak of file descriptors (#292).
Merge pull request #293 from project-hatohol/issue-292

[Helpers] Fix a leak of file descriptors (#292).