Closed some input streams to prevent resource leaks