https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103560
--- Comment #8 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Tobias Burnus <bur...@gcc.gnu.org>: https://gcc.gnu.org/g:5e33fea21957c97d63e3738be6056ae2a94e3284 commit r12-7787-g5e33fea21957c97d63e3738be6056ae2a94e3284 Author: Tobias Burnus <tob...@codesourcery.com> Date: Wed Mar 23 16:54:12 2022 +0100 Fortran: Fix directory stat check for '.' [PR103560] MinGW does not like a call to 'stat' for './' via gfc_do_check_include_dir. Solution: Only append '/' when concatenating the path with the filename. gcc/fortran/ChangeLog: PR fortran/103560 * scanner.cc (add_path_to_list): Don't append '/' to the save include path. (open_included_file): Use '/' in concatenating path + file name. * module.cc (gzopen_included_file_1): Likewise. gcc/testsuite/ChangeLog: PR fortran/103560 * gfortran.dg/include_14.f90: Update dg-warning. * gfortran.dg/include_17.f90: Likewise. * gfortran.dg/include_18.f90: Likewise. * gfortran.dg/include_6.f90: Update dg-*.