fixes an issue with InputStreams that contain trailer records

Trailer records were not handled correctly in input streams.  The body parser would be used on the trailer record because the nextLine member variable would never be updated to null at the end of the file.