Charles Davis cdavis@mymail.mines.edu writes:
If the volume is indeed case insensitive, we skip searching through the whole directory ourselves, and just stat() each portion of the path.
You still have extra stat calls. You should stop trying to pass a case_sensitive flag to find_file_in_dir and have it take care of everything internally, if and only if a case insensitive search seems to be required.