This reformulates the in-buffer optimisation check to match the code in _IO_new_file_seekoff. No functional changes, but easier to understand. (cherry picked from commit d840539e)