Once you have finished reading information from a file, you should so indicate by sending a close message to the stream:
close
inputStream close.