Close the FileInputStream to avoid lock

Resolves #1, on Windows files are locked while they are open and cannot be deleted.