file reading debugged