Fix select by indentation bug at EOF.

Added some error-catching code in order to allow for the "end of file" error when the starting indentation level would run all the way to the end of the file.