Fixed issue of multiple threads reading from the same file.